Saving problems in the Interactive Optimizer
CPLEX offers several file formats to save a problem in the Interactive Optimizer.
The Interactive Optimizer available in IBM CPLEX Optimizer for z/OS recognizes only EBCDIC IBM-1047. The following information applies to the Interactive Optimizer available on other platforms.
In the Interactive Optimizer, you save information about the problem currently in memory as a
file in the LP, MPS, or SAV formats by means of the write
command and its options.
For a complete list of file formats that CPLEX supports, see File formats supported by CPLEX. Here are the options in the Interactive Optimizer
for frequently used formats:
Use the
bas
option to save a problem basis in MPS format.Use the
clp
option to write a conflict subproblem.Use the
flt
option to write filters for the solution pool.Use the
mst
option to write MIP start files. This option also applies to solutions in the solution pool. In fact, an additional option specifies whether to write a single solution specified by its index, or to write all solutions from the solution pool as MIP starts.Use the
pre
option to write a SAV file for the reduced, presolved problem formulation.Use the
prm
option to write a file of nondefault parameter settings.Use the
sol
option to write solution files. This option also applies to solutions in the solution pool. In fact, an additional option specifies whether to write a single solution specified by its index, or to write all solutions from the solution pool.
The SAV file format, because it is binary, is the format that preserves the greatest degree of precision in data. It can be effective in reducing read and write time for repetitively solved problems. However, because it is a binary format, it cannot be readily viewed or edited in standard text editors.
As a naming convention, it is a good idea to use the
file format for reading the file as the file extension when you write
or save the file (for instance, example.bas
, example.lp
, example.mps
, example.sav
).
When you follow this convention, CPLEX automatically recognizes
the file type and eliminates additional prompts for you to specify
a file type.