anyone knows if I can use the solver CLP in my problem modeled in PyOMO? I found only informations about the old version of pyomo where this was not possible. I'd like to know if it still impossible to use them together. Thanks in advance.
Pyomo is able to use the CBC solver through the AMPL solver library interface. The default linear solver in CBC is CLP. You could go that route.
Upshot: if you call the CBC solver from Pyomo with a linear model, it should be solved using CLP.
Related
I want to model an optimization problem that contains quite some bilinear terms. As such, I want to make use of the functionality of Gurobi 9.0 to solve bilinear problems. Clearly, I can use the GurobiPy API. However, I might want to compare other solvers (like BARON). So, I wonder whether it is possible to use Pyomo to formulate the problem and then solve it using Gurobi? Will there be any problems?
As far as I can tell, there should not be a problem. The same Gurobi solver will be used. Your problem will just be modelled in a somewhat different syntax (PYOMO) which is easily portable for solving with a wider range of solvers.
If still in doubt, I suggest you try a very simple problem with a bilinear term.
Note however that BARON requires a commercial license unlike Gurobi which offers free academic licenses.
Best of luck!
I would like to know if there is a way to take a non linear model in pyomo format from the user, and load it into the pyomo optimization code. I'm asking this since i'm dealing with non linear models, and need to develop a generic code to implement a particular type of optimization using these models. Kindly help me out.
Thank you
I'd like to know if it is possible to introduce an initial basic feasible solution to the simplex in glpk, this in order to avoid de initialization phase of the algorithm and save computation time. I also want to know if glpk library uses the standard simplex or the revised simplex. Thanks.
Yes, you can set a custom basis by using
glp_set_col_stat(). You will have to set each column to be Basic (GLP_BS) or Non-basic (GLP_NL). You could also use the API glp_adv_basis method, though I don't think it lets you customize the basis.
I recommend the very readable Section 2.6 in the LP Basis Construction Routines here.
And yes, GLPK uses the Revised Simplex. I believe this is the default setting.
I wrote a code which solves large systems of PDEs using some discretization methods which basically involves solving large, sparse systems Ax=b many times at each time steps.
I currently use the PARDISO solver (from the intel MKL library) which is a direct LU factorization of A to solve the system. I would like to compare this method with the use of iterative solvers (which, with the use of preconditioners, might perform better since I could use the same preconditioner over many time steps if my Jacobian matrix does not vary too much).
My question is then, what library do you suggest for sparse iterative solvers in fortran ? I found one (SLATEC) which was written in 1993 so I wonder if there is something more performant which was written more recently ?
Thanks :)
I would also add:
LIS
AGMG
Oh, well ... the complete list of Linear Algebra Solvers
Thanks for the comments, PETSc seems to be exactly what I was looking for, just need to learn how to link C calls into fortran now :)
For my research I'm confronted with a system of linear diophantine equations.
I found several research papers on the topic but before I start to create
a solver myself, I would like to know if one does know of a (lightweight)
C++ math library, which solves such a system.
I suggest to try to use Octave embedded:
http://octave.sourceforge.net/docs.html