Download AMPL CPLEX 9.0 User Guide

Transcript
C
H
A
P
T
E
R
3
AMPL-Solver Interaction
Choosing a Solver
AMPL's solver interface supports linear, nonlinear, and mixed integer models with no builtin size limitations. This interface is rich enough to support many of the features used by
advanced solvers to improve performance and solution accuracy, such as piecewise-linear
constructs, representation of network problems, and automatic differentiation of nonlinear
functions. To take advantage of these features, solvers must be written to utilize AMPL's
interface. ILOG provides no support for the usage of AMPL with solvers not distributed by
ILOG.
You choose a solver for a particular problem by giving its executable filename in the AMPL
option solver command. For example, to use the (AMPL-compatible) CPLEX solver,
type:
ampl: option solver cplexamp;
Most solvers have algorithmic options, such as CPLEX with its Mixed Integer and Barrier
options. In these cases, you give the solver executable name to AMPL (for example, with
option solver cplexamp); the solver will determine, from the problem characteristics
as passed by AMPL (for example, a quadratic objective or integer variables) as well as
solver options you specify, which algorithmic options will be used.
ILOG AMPL CPLEX SYSTEM 9.0 — USER’S GUIDE
11