12.07.2015 Views

ILOG CPLEX 11.0 User's Manual

ILOG CPLEX 11.0 User's Manual

ILOG CPLEX 11.0 User's Manual

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Saving QP ProblemsAfter you enter a QP problem, whether interactively or by reading a formatted file, you canthen save the problem in a formatted file. The formats available to you are LP, MPS, andSAV. When you save a QP problem in one of these formats, the quadratic information willalso be recorded in the formatted file.Changing Problem Type in QPsConcert Technology (that is, applications written in the C++, Java, or .NET API of<strong>ILOG</strong> <strong>CPLEX</strong>) treats all models as capable of containing quadratic coefficients in theobjective function. These coefficients can therefore be added or deleted at will. Whenextracting a model with a quadratic objective function, IloCplex will automatically detectit as a QP and make the required adjustments to data structures.However, the other ways of using <strong>ILOG</strong> <strong>CPLEX</strong> (the Callable Library and the InteractiveOptimizer) require an explicit problem type to distinguish Linear Programs (LPs) from QPs.The following sections discuss the topic for these users.When you enter a problem, <strong>ILOG</strong> <strong>CPLEX</strong> discovers the problem type from the availableinformation. When read from a file (LP, MPS, or SAV format, for example), or enteredinteractively, a continuous optimization problem is usually treated as being of type qp ifquadratic coefficients are present in the objective function and no quadratic terms are presentamong the constraints. (Quadratic terms among the constraints may make a problem of typeQCP. For more about that type, see Solving Problems with Quadratic Constraints (QCP) onpage 239.) Otherwise, the problem type is usually lp. The issue of problem types thatsupport integer restrictions in conjunction with quadratic variables is discussed in SolvingMixed Integer Programming Problems (MIP) on page 255.If you enter a problem that lacks any quadratic coefficients, its Problem Type is initially lp.If you then wish to modify the problem to contain quadratic coefficients in the objectivefunction, you do this by first changing the Problem Type to qp. Conversely, if you haveentered a QP model and wish to remove all the quadratic coefficients from the objectivefunction and thus convert the model to an LP, you can change the Problem Type to lp. Notethat deleting each of the quadratic coefficients individually still leaves the Problem Type asqp, although in most instances the distinction between this problem and its lp or qpcounterpart is somewhat arbitrary in terms of the steps to solve it.When using the Interactive Optimizer, you use the command change problem with one ofthe following options:◆lp indicates that you want <strong>ILOG</strong> <strong>CPLEX</strong> to treat the problem as an LP. This change inProblem Type removes from your problem all the quadratic information, if there is anypresent.232 <strong>ILOG</strong> <strong>CPLEX</strong> <strong>11.0</strong> — USER’ S MANUAL

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!