Solver drivers

‘Flat API’ solvers

For solvers with traditional ‘flat’ (no expression trees) APIs, non-linear AMPL expressions need to be reformulated. For example, max(a, b) is translated into a constraint

new_var == max(a, b);

which is in turn reformulated for MIP or passed to the solver natively (e.g., Gurobi: GRBaddgenconstrMax). See the Modeling guide for MP-based AMPL solvers.

There are several implementations, see Modeling overview.

Expression-based solvers

Expression-based solver APIs can efficiently map NL forests. For example, AMPL expression exp() maps to IBM ILOG Concert’s IloExponent. The library has the following C++ drivers of this kind, all of which support AMPL extensions for logic and constraint programming:

Specialized drivers

  • SOCP solver uses IBM ILOG CPLEX to solve problems convertable to SOCP form.

  • SSD solver is a solver for problems with second-order stochastic dominance constraints.

  • SMPSWriter, a converter from deterministic equivalent of a two-stage stochastic programming (SP) problem written in AMPL to an SP problem in SMPS format.