I'm solving the VRP with Scip and want to choose the algorithm. In some of my instances, Scip solves the problem without the branch-and-bound tree in the root node; here I think cutting planes are executed. Cplex for example can choose prim Simplex or dual Simplex etc. to solve the Problem in this case.
Is there a possibility in Scip too? I use the parameters lp/initalgorithm=b (barrier) and lp/resolvealgorithm=b to make sure, in the branch-and-bound tree only this algorithm is used. But when Scip solves the problem in the root node, these parameters change nothing.
Thanks for your help!
So if I understand you correctly you want to always use barrier to solve the LP relaxations of your problem?
You need to make sure that the LP solver you are using supports this. If you use SoPlex as the LP solver in SCIP it does not have a barrier algorithm implemented and will fallback to solving with dual Simplex instead.
The LP solvers that support barrier are Cplex, Xpress, Gurobi, Mosek, and CLP
Related
I want to just be sure that I am eligible to use Bonmin and Couenne for solving just the NLP problem (Still I do not have integer variable) and I am eager to obtain global optimum not local. I also read that Ipopt first search for the global answer and if it does not find that it will provide a local answer. How I can understand my answer is a global answer when I using Ipopt. Also, I want to what is the best NLP and MINLP open source pythonic solvers for these issues that can be merged with Pyomo?
The main reason for my question is the following output using Bonmin:
NOTE: You are using Ipopt by default with the MUMPS linear solver.
Other linear solvers might be more efficient (see Ipopt documentation).
Regards
Some notes:
(1) "Ipopt first search for the global answer and if it does not find that it will provide a local answer" This is probably not how I would phrase it. IPOPT finds local solutions. For some problems these will be the global solution. For convex problems, this is always the case (except for numerical issues).
(2) Bonmin is a local MINLP solver, Couenne is a global NLP/MINLP solver. Typically Bonmin can solve larger problems than Couenne, but you get local solutions.
(3) "NOTE: You are using Ipopt by default with the MUMPS linear solver. Other linear solvers might be more efficient (see Ipopt documentation)." This is just a notification that you are using IPOPT with linear algebra routines from MUMPS. There are other linear sub-solvers that IPOPT can use and that may perform better on large problems. Often the HARWELL routines (typically called MAnn) give better performance. MUMPS is free while the Harwell routines require a license.
In a follow-up answer (well it is not answer at all) it is stated:
Regarding Ipopt how I can understand that it is finding the global
solution or local optimum? the code will notify that? Regarding to
Bonmin according to AMPL page AMPL It provides the global solution for
the convex problem " Finds globally optimal solutions to convex
nonlinear problems in continuous and discrete variables, and may be
applied heuristically to nonconvex problems." And you were saying that
it is obtained the local solution, I am a bit confused on this part.
But the general question about all those codes is that how I can find
out that the answer is global optimum?
(a) Ipopt does not know if a solution is a local or a global optimal solution. For convex problems a local optimum is a global optimal solution. You will need to convince yourself the problem you pass on to Ipopt is convex (Ipopt will not do this for you).
(b) Bonmin: the same: if the problem is convex it will find global solutions. Otherwise you will get a local solution. You will get no notification whether a solution is a global solution: Bonmin does not know if a solution is a global optimum.
(c) When looking for guaranteed global solutions you can use a local solver only when the problem is convex. For other problems you need a global solver. Another approach is to use a multi-start algorithm with a local solver. That gives you confidence that you are not ending up with a bad local optimum.
If possible, I suggest to discuss this with your teacher. These concepts are important to understand (and most solver manuals assume you know about them).
I think the ug use scip to solve ILP problems. But I want to solve LP problems with ug and can not find the parameters to configure ug to solve with soplex.
Is it possible to do so, or the LP solver is scalable enough and does not the trouble?
UG is a framework for parallelizing the tree search. While there are some tricks to speed up the root as well (racing stage), it's best suited for MIP instances that require a lot of branch and bound nodes.
If you want to solve an LP in parallel, I suggest you try an interior point, aka barrier solver, as is implemented in CPLEX, Gurobi or Xpress. SoPex is a sequential simplex solver.
As far as i know Gurobi resumes optimizing where it left after calling Model.Terminate() and then calling Model.Optimize() again. So I can terminate and get the best solution so far and then proceed.Now I want to do the same, but since I want to use parts of the suboptimal solution I need to set some variables to fixed values before I call Model.Optimize() again and optimize the rest of the model. How can i do this so that gurobi does not start all over again?
First, it sounds like you're describing a mixed-integer program (MIP); model modification is different for continuous optimization (linear programming, quadratic programming).
When you modify a MIP model, the tree information is no longer helpful. Instead, you must resolve the continuous (LP) relaxation and create a new branch-and-cut tree. However, the prior solution may still be used as a MIP start, which can reduce the solve time for the second model.
However, your method may be redundant with the RINS algorithm, which is an automatic feature of Gurobi MIP. You can control the behavior of RINS via the parameters RINS, SubMIPNodes and Heuristics.
I know that column generation gives an optimal solution and it can be used with other heuristics. But does that make it an exact algorithm? Thanks in advance.
Traditional CG operates on the relaxed problem. Although it finds the optimal LP solution, this may not translate directly into an optimal MIP solution. For some problems (e.g. 1d cutting stock) there is evidence this gap is small, and we just apply the set of columns found for the relaxed problem to a final MIP knowing this is a good solution but necessarily optimal. So it is a heuristic.
With some effort you can use column generation inside a branch-and-bound algorithm (this is called branch-and-price). This gives proven optimal solutions.
An exact algorithm means that the algorithm can solve the optimization problem globally i.e it has given the global optima.
Column generation technique is conventionally applied to relaxed LP problem and tries to optimize the relaxed LP problem by constantly improving the current solution with the help of dual multipliers. It gives an exact LP solution for the relaxed LP problem. But sometimes in real-world problems, the exact solution of the relaxed Lp problem is not feasible to use, it needs to be translated to an integer solution in order to use it. Now if the problem scale is small, then there are many exact MIP algorithms (such as Branch and Bound) which can solve it exactly and give an integer solution. But if the problem is large-scale, even the exact MIP algorithms can take longer runtimes, hence, we use some special/intelligent heuristics to lower the difficulty of the MIP problem.
Summary: Column generation is an exact technique for solving the relaxed LP problem, not the original IP problem.
First, strictly speaking, all algorithms are heuristic, including Simplex Method.
Second, I think Column generation is a heuristic algorithm, because it solves the LP relaxation of the master problem. It does not guarantee IP optimal. Actually CG does not always converge very well.
I'm implementing a branch and price algorithm in c using SCIP.
Question: To call the branching mechanism, I use the basic BRANCHEXECLP mechanism. How does SCIP know when to branch? When the current relaxation solution has non-integer solutions, right? I don't have to tell SCIP to invoked the branching mechanism for this case, right?
I'm asking because (for the most part) my B&P algorithm is working well. But, at some point it reaches a node corresponding to the dual bound solution. After solving the pricing problem (and no columns are attractive to enter the master problem), the relaxation solution at this node contains non-integer solutions, but the branching mechanism is not invoked. The run just quits. Any idea as to what is going on here?
Thanks,
Rob Curry
I guess you checked during pricing that there are fractional variables in the current LP solution?
And the dual bound at that node equals the global dual bound? Did you mark your objective to only have integral values? In that case, if the dual bound is close enough to the primal bound that rounding it up gives the same number, SCIP will just cut off the node. Perhaps also SCIP found a new solution after your pricing which was immediately proven to be optimal by the current global dual bound? SCIP automatically runs some simple rounding heuristics after each solved LP in the pricing loop.