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.

◆◆If data already exist in MPS, SAV, or LP format in a file, you can callCPXreadcopyprob to read that file and copy the data into the problem object.Mathematical Programming System (MPS) is an industry-standard format for organizingdata in mathematical programming problems. LP and SAV file formats are<strong>ILOG</strong> <strong>CPLEX</strong>-specific formats for expressing linear programming problems asequations or inequalities. Understanding File Formats on page 144 explains theseformats briefly. They are documented in the reference manual <strong>ILOG</strong> <strong>CPLEX</strong> FileFormats.You can assemble arrays of data and then call CPXcopylp to copy the data into theproblem object.Whenever possible, compute your problem data in double precision (64 bit). Computers arefinite-precision machines, and truncating your data to single precision (32 bit) can result inunnecessarily ill-conditioned problems For more information, refer to Numeric Difficultieson page 185.Optimize the ProblemCall one of the <strong>ILOG</strong> <strong>CPLEX</strong> optimizers to solve the problem object that you haveinstantiated and populated. Choosing an Optimizer for Your LP Problem on page 172explains in greater detail how to choose an appropriate optimizer for your problem.Change the Problem ObjectIn analyzing a given mathematical program, you may make changes in a model and studytheir effect. As you make such changes, you must keep <strong>ILOG</strong> <strong>CPLEX</strong> informed about themodifications so that <strong>ILOG</strong> <strong>CPLEX</strong> can efficiently re-optimize your changed problem.Always use the problem modification routines from the Callable Library to make suchchanges and thus keep <strong>ILOG</strong> <strong>CPLEX</strong> informed. In other words, do not change a problem byaltering the original data arrays and calling CPXcopylp again. That tempting strategyusually will not make the best use of <strong>ILOG</strong> <strong>CPLEX</strong>. Instead, modify your problem by meansof the problem modification routines. Use the routines whose names begin with CPXchg tomodify existing objects in the model, or use the routines CPXaddcols, CPXaddqconstr,CPXaddrows, CPXnewcols, and CPXnewrows to add new constraints and new variables tothe model.For example, let’s say a user has already solved a given LP problem and then changes theupper bound on a variable by means of an appropriate call to the Callable Library routineCPXchgbds. <strong>ILOG</strong> <strong>CPLEX</strong> will then begin any further optimization from the previousoptimal basis. If that basis is still optimal with respect to the new bound, then <strong>ILOG</strong> <strong>CPLEX</strong>will return that information without even needing to refactor the basis.<strong>ILOG</strong> <strong>CPLEX</strong> <strong>11.0</strong> — USER’ S MANUAL 113

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

Saved successfully!

Ooh no, something went wrong!