I know that for some solvers, for example, the constraint programming solver in Google OR-Tools, it is possible to see all the intermediate solutions that the solver finds while it searches for an optimal solution. (An example is in this link.) I need these step-wise partial solutions to visualize the evolution of the optimization process in a physical example where I have a nonlinear 0-1 integer problem that I programmed in AMPL.

My questions are:

  • When solving nonlinear 0-1 integer problems, is it logical to consider such intermediate solutions?

  • Is it possible to obtain the intermediate solutions of solvers using AMPL? Which solvers have such a feature for AMPL?


1 Answer 1


Yes it is reasonable. For problems where closing the optimality gap is difficult, you may want to save e.g. the 10 best solutions found before termination. This is called a solution pool and it is a solver specific option that you must pass to the solver from AMPL (check the solvers' manuals for "solution pool").

Most linear solvers support this (including CPLEX and GUROBI) - as for NLP solvers I believe that BARON supports this as well.

  • 1
    $\begingroup$ Thank you very much for your helpful answer. I looked at BARON's user manual and found very useful information about ''solution pool". $\endgroup$ Commented Aug 24, 2019 at 20:03

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.