The OPTLP Procedure
PROC OPTLP Statement
PROC OPTLP <options>;
You can specify the following options in the PROC OPTLP statement.
Data Table Options
- DATA=CAS-libref.data-table
specifies the input data table that corresponds to the LP model. If this option is not specified, PROC OPTLP uses the most recently created data table. For more information about the input data table, see Chapter 8, The MPS-Format Data Table. libref.data-table is a two-level name, where libref refers to the library, and data-table specifies the name of the input data table. For more information about this two-level name, see the section Using CAS Sessions and CAS Engine Librefs in Chapter 3, Shared Concepts.
-
DUALIN=CAS-libref.data-table
DIN=CAS-libref.data-table specifies the input data table that corresponds to the dual solution that is required for warm starting the primal and dual simplex algorithms. For more information, see the section Data Input and Output. libref.data-table is a two-level name, where libref refers to the library, and data-table specifies the name of the input data table. For more information about this two-level name, see the section Using CAS Sessions and CAS Engine Librefs in Chapter 3, Shared Concepts.
-
DUALOUT=CAS-libref.data-table
DOUT=CAS-libref.data-table specifies the output data table for the dual solution. This data table contains the dual solution information. For more information, see the section Data Input and Output. libref.data-table is a two-level name, where libref refers to the library, and data-table specifies the name of the output data table. For more information about this two-level name, see the section Using CAS Sessions and CAS Engine Librefs in Chapter 3, Shared Concepts.
-
OBJCONSTANT=number
OBJECTIVECONSTANT=number specifies the constant part of the objective, where number can be any number. This option supersedes the objective right-hand side that is specified in the input data table. By default, OBJCONSTANT=0.
- OBJSENSE=MIN | MAX
specifies whether the LP model is a minimization or a maximization problem. Specify OBJSENSE=MIN for a minimization problem and OBJSENSE=MAX for a maximization problem. Alternatively, you can specify the objective sense in the input data table; for more information, see the section ROWS Section. If the objective sense is specified differently in this option and in the input data table, this option supersedes the objective sense that is specified in the input data table. If the objective sense is not specified anywhere, then PROC OPTLP interprets and solves the linear program as a minimization problem.
-
PRIMALIN=CAS-libref.data-table
PIN=CAS-libref.data-table specifies the input data table corresponding to the primal solution that is required for warm starting the primal and dual simplex algorithms. See the section Data Input and Output for details. libref.data-table is a two-level name, where libref refers to the library, and data-table specifies the name of the input data table. For more information about this two-level name, see the section Using CAS Sessions and CAS Engine Librefs in Chapter 3, Shared Concepts.
-
PRIMALOUT=CAS-libref.data-table
POUT=CAS-libref.data-table specifies the output data table for the primal solution. This data table contains the primal solution information. See the section Data Input and Output for details. libref.data-table is a two-level name, where libref refers to the library, and data-table specifies the name of the output data table. For more information about this two-level name, see the section Using CAS Sessions and CAS Engine Librefs in Chapter 3, Shared Concepts.
Solver Options
-
ALGORITHM=option
SOLVER=option
SOL=option -
specifies an LP algorithm. You can specify the following options:
- PRIMAL (PS)
uses the primal simplex algorithm.
- DUAL (DS)
uses the dual simplex algorithm.
- NETWORK (NS)
uses the network simplex algorithm.
- INTERIORPOINT (IP)
uses the interior point algorithm.
- CONCURRENT (CON)
uses several different algorithms in parallel.
- SIFTING (SIFT)
uses the sifting algorithm.
- SIMPLEX (SPX)
uses one of the simplex-based algorithms: PS, DS, NS, and SIFT. The algorithm is determined automatically on the basis of the problem structure.
The valid abbreviated value for each option is indicated in parentheses. By default, ALGORITHM=SIMPLEX.
-
ALGORITHM2=option
SOLVER2=option -
specifies an LP algorithm if ALGORITHM=NS. You can specify the following values:
- PRIMAL (PS)
uses the primal simplex algorithm (after network simplex).
- DUAL (DS)
uses the dual simplex algorithm (after network simplex).
The valid abbreviated value for each option is indicated in parentheses. By default, the OPTLP procedure decides which algorithm is best to use after calling the network simplex algorithm on the extracted network.
- IIS=FALSE | TRUE
-
specifies whether PROC OPTLP attempts to identify a set of constraints and variables that form an irreducible infeasible set (IIS). You can specify the following values:
- FALSE
disables IIS detection.
- TRUE
enables IIS detection.
If an IIS is found, information about infeasible constraints or variable bounds can be found in the DUALOUT= and PRIMALOUT= data tables. For more information about IIS, see the section Irreducible Infeasible Set. By default, IIS=FALSE.
Presolve Options
- DUALIZE=AUTOMATIC | OFF | ON
-
controls the dualization of the problem. You can specify the following values:
- AUTOMATIC
specifies that the presolver use a heuristic to decide whether to dualize the problem or not.
- OFF
disables dualization. The optimization problem is solved in the form that you specify.
- ON
specifies that the presolver formulate the dual of the linear optimization problem.
Dualization is usually helpful for problems that have many more constraints than variables. You can use this option with all simplex algorithms in PROC OPTLP, but it is most effective with the primal and dual simplex algorithms.
By default, DUALIZE=AUTOMATIC.
- FOLD=AUTOMATIC | OFF | ON
-
controls the folding of the problem. You can specify the following values:
- AUTOMATIC
specifies that the presolver use a heuristic to decide whether to fold the problem or not.
- OFF
disables folding. The optimization problem is not further reduced by folding.
- ON
specifies that the presolver try to fold the linear optimization problem.
Folding is helpful for problems that have a symmetric structure. When you use this option with a simplex algorithm in PROC OPTLP, a crossover step must be used to find a basic solution.
By default, FOLD=AUTOMATIC.
-
PRESOLVER=AUTOMATIC | NONE | BASIC | MODERATE | AGGRESSIVE
PRESOL=AUTOMATIC | NONE | BASIC | MODERATE | AGGRESSIVE -
specifies the level of presolve processing. You can specify the following values:
- AUTOMATIC
applies the presolver by using the default settings. Suitable limits are in place such that the presolver reduces the problem almost as much as when PRESOLVER=AGGRESSIVE, but in a reasonable time.
- NONE
disables the presolver. Only the necessary problem transformation steps are performed.
- BASIC
performs a basic presolve, such as removing empty rows, columns, and fixed variables. Only some very fast operations are performed.
- MODERATE
performs a basic presolve and applies other inexpensive presolve techniques. Suitable limits are in place such that the presolver reduces the problem almost as much as when PRESOLVER=AGGRESSIVE, but in a reasonable time.
- AGGRESSIVE
performs a moderate presolve and applies other aggressive (but computationally expensive) presolve techniques. All the presolver techniques are called with no limits. This reduces the problem the most, but can take a very long time.
By default, PRESOLVER=AUTOMATIC. For more information, see the section Presolve.
Control Options
-
FEASTOL=
specifies the feasibility tolerance
[1E–9, 1E–4] for determining the feasibility of variable and constraint values. The default value is 1E–6. Both simplex and interior point algorithms use the relative error for the computation of feasibility tolerance.
-
LOGFREQ=k
PRINTFREQ=k -
specifies that the printing of the solution progress to the iteration log is to occur after every k iterations. The print frequency, k, is an integer between zero and the largest four-byte signed integer, which is
.
The value k = 0 disables the printing of the progress of the solution.
If the LOGFREQ= option is not specified, then PROC OPTLP displays the iteration log with a dynamic frequency according to the problem size if the primal or dual simplex algorithm is used, with frequency 10,000 if the network simplex algorithm is used, or with frequency 1 if the interior point algorithm is used.
- LOGLEVEL=NONE | BASIC | MODERATE | AGGRESSIVE
-
controls the amount of information that PROC OPTLP displays in the SAS log, from a solver summary to details at each iteration. You can specify the following values:
- NONE
turns off all solver-related messages in the SAS log.
- BASIC
displays a solver summary after stopping.
- MODERATE
prints a solver summary and an iteration log by using the value that you specify in the LOGFREQ= option.
- AGGRESSIVE
prints a detailed solver summary and an iteration log by using the value that you specify in the LOGFREQ= option.
By default, LOGLEVEL=MODERATE.
- MAXITER=k
specifies the maximum number of iterations. The value k can be any integer between one and the largest four-byte signed integer, which is
. If you do not specify this option, the procedure does not stop based on the number of iterations performed. For network simplex, this iteration limit corresponds to the algorithm called after network simplex (either primal or dual simplex).
- MAXTIME=t
specifies an upper limit of t units of time for reading in the data and performing the optimization process. The value of the TIMETYPE= option determines the type of units used. If you do not specify this option, the procedure does not stop based on the amount of time elapsed. The value of t can be any positive number; the default value is the positive number that has the largest absolute value that can be represented in your operating environment.
-
OPTTOL=
specifies the optimality tolerance
[1E–9, 1E–4] for declaring optimality. The default value is 1E–6. Both simplex and interior point algorithms use the relative error for the computation of optimality tolerance.
-
PRINTLEVEL=0
1
2
-
specifies whether to print a summary of the problem and solution. You can specify the following values:
- 0
neither produces nor prints any Output Delivery System (ODS) tables.
- 1
prints the ODS tables ProblemSummary, SolutionSummary, and PerformanceInfo.
- 2
prints the same tables as PRINTLEVEL=1 along with an additional table called ProblemStatistics.
For more information about the ODS tables created by PROC OPTLP, see the section ODS Tables. By default, PRINTLEVEL=1.
- TIMETYPE=CPU | REAL
-
specifies the units of time used by the MAXTIME= option and reported by the PRESOLVE_TIME and SOLUTION_TIME terms in the _OROPTLP_ macro variable. You can specify the following values:
- CPU
specifies units of CPU time.
- REAL
specifies units of real time.
By default, TIMETYPE=REAL.
Simplex Algorithm Options
- BASIS=CRASH | SLACK | WARMSTART
-
specifies the option for generating an initial basis. You can specify the following values:
- CRASH
generates an initial basis by using crash techniques (Maros 2003). The procedure creates a triangular basic matrix consisting of both decision variables and slack variables.
- SLACK
generates an initial basis by using all slack variables.
- WARMSTART
starts the primal and dual simplex algorithms with a user-specified initial basis. The PRIMALIN= and DUALIN= data tables are required to specify an initial basis.
The default option is determined automatically based on the problem structure. For network simplex, this option has no effect.
- PRICETYPE=DEVEX | FULL | HYBRID | PARTIAL | STEEPESTEDGE
-
specifies the pricing strategy for the primal and dual simplex algorithms. You can specify the following values:
- DEVEX
uses the Devex pricing strategy.
- FULL
uses Dantzig’s rule on all decision variables.
- HYBRID
uses a hybrid of the Devex and steepest-edge pricing strategies. This strategy is available only for the primal simplex algorithm.
- PARTIAL
uses Dantzig’s rule on a queue of decision variables. Optionally, you can specify QUEUESIZE=k. This strategy is available only for the primal simplex algorithm.
- STEEPESTEDGE
uses the steepest-edge pricing strategy.
The default option is determined automatically according to the problem structure. For the network simplex algorithm, this option applies only to the algorithm that is specified in the ALGORITHM2= option. For more information, see the section Pricing Strategies for the Primal and Dual Simplex Algorithms.
- QUEUESIZE=k
specifies the queue size
, where n is the number of decision variables. This queue is used for finding an entering variable in the simplex iteration. The default value is chosen adaptively based on the number of decision variables. This option is used only when PRICETYPE=PARTIAL.
- SCALE=AUTOMATIC | NONE
-
specifies a scaling option. You can specify the following values:
- AUTOMATIC
automatically applies scaling procedure if necessary.
- NONE
disables scaling.
By default, SCALE=AUTOMATIC.
- SEED=number
specifies the initial seed for the random number generator. Because the seed affects the perturbation in the simplex algorithms, the result might be a different optimal solution and a different solver path, but the effect is usually negligible. The value of number can be any positive integer up to the largest four-byte signed integer, which is
. By default, SEED=100.
Interior Point Algorithm Options
- CROSSOVER=FALSE | TRUE
-
specifies whether to convert the interior point solution to a basic simplex solution. If the interior point algorithm terminates with a solution, the crossover algorithm uses the interior point solution to create an initial basic solution. After performing primal fixing and dual fixing, the crossover algorithm calls a simplex algorithm to locate an optimal basic solution.
You can specify the following values:
- FALSE
does not convert the interior point solution to a basic simplex solution.
- TRUE
converts the interior point solution to a basic simplex solution.
By default, CROSSOVER=TRUE.
-
DUALITYGAP=
specifies the desired relative duality gap
[1E–9, 1E–4], which is the relative difference between the primal and dual objective function values and is the primary solution quality parameter. For more information, see the section The Interior Point Algorithm. The default value is 1E–6.
Parallel Options
The OPTLP procedure has several components that take advantage of shared-memory parallel architectures. You can use the following options to control parallel processing:
- DETERMINISTIC=TRUE | FALSE
-
specifies whether to run PROC OPTLP in deterministic or nondeterministic parallel mode. You can specify the following values:
- TRUE
runs PROC OPTLP in deterministic parallel mode.
- FALSE
runs PROC OPTLP in nondeterministic parallel mode.
By default, DETERMINISTIC=TRUE.
- NTHREADS=number
specifies the maximum number of threads for PROC OPTLP to use for multithreaded processing. The value of number can be any integer between 1 and 256, inclusive. The default is the number of cores on the machine that executes the process or the number of cores permissible based on your installation (whichever is less). The number of simultaneously active CPUs is limited by your installation and license configuration.