The OPTLP Procedure

Example 10.2 Using the Interior Point Solver

You can also solve the oil refinery problem described in Example 10.1 by using the interior point solver. You can create the input data set from an external MPS-format flat file by using the SAS macro %MPS2SASD or SAS DATA step code, both of which are described in Getting Started: OPTLP Procedure. You can use the following SAS code to solve the problem:

proc optlp data=ex1
  objsense  = max
  algorithm = ip
  primalout = ex1ipout
  dualout   = ex1idout
  logfreq   = 1;
run;

The optimal solution is displayed in Output 10.2.1.

Output 10.2.1: Interior Point Solver: Primal Solution Output

Primal Solution

Obs Objective Function ID RHS ID Variable
Name
Variable
Type
Objective
Coefficient
Lower
Bound
Upper Bound Variable Value Variable
Status
Reduced Cost
1 profit   a_l D -175 0 110 110.000   10.2083
2 profit   a_h D -165 0 165 0.000   -22.8125
3 profit   br D -205 0 80 80.000   2.8125
4 profit   na_l N 0 0 1.7977E308 7.450   0.0000
5 profit   na_i N 0 0 1.7977E308 21.800   0.0000
6 profit   h_o N 0 0 1.7977E308 77.300   0.0000
7 profit   j_1 N 350 0 1.7977E308 72.667   0.0000
8 profit   j_2 N 350 0 1.7977E308 33.042   0.0000


The iteration log is displayed in Output 10.2.2.

Output 10.2.2: Log: Solution Progress

NOTE: The problem EX1 has 8 variables (0 free, 0 fixed).                        
NOTE: The problem has 6 constraints (3 LE, 3 EQ, 0 GE, 0 range).                
NOTE: The problem has 19 constraint coefficients.                               
WARNING: The objective sense has been changed to maximization.                  
NOTE: The LP presolver value AUTOMATIC is applied.                              
NOTE: The LP presolver removed 3 variables and 3 constraints.                   
NOTE: The LP presolver removed 6 constraint coefficients.                       
NOTE: The presolved problem has 5 variables, 3 constraints, and 13 constraint   
      coefficients.                                                             
NOTE: The LP solver is called.                                                  
NOTE: The Interior Point algorithm is used.                                     
NOTE: The deterministic parallel mode is enabled.                               
NOTE: The Interior Point algorithm is using up to 4 threads.                    
                                           Primal        Bound         Dual     
      Iter   Complement  Duality Gap       Infeas       Infeas       Infeas     
         0  4.06515E+01  2.05269E+00  1.13742E-14  0.00000E+00  2.70189E-01     
         1  6.98840E+00  3.06315E+00  6.77873E-15  0.00000E+00  5.33713E-02     
         2  5.99555E+00  3.57653E-01  2.93104E-14  0.00000E+00  4.88028E-02     
         3  1.39762E+00  1.01631E-01  2.62511E-14  5.55800E-17  1.04677E-02     
         4  1.03056E+00  6.83923E-02  4.42791E-14  1.10891E-16  5.86194E-03     
         5  2.52016E-02  2.98995E-04  3.82469E-14  1.13953E-16  2.08475E-04     
         6  2.52303E-04  3.02383E-06  3.45164E-14  2.49422E-16  2.08475E-06     
         7  6.82704E-04  3.62810E-08  7.84605E-15  3.96766E-17  4.54026E-06     
         8  6.82704E-06  3.62807E-10  2.49698E-15  2.54085E-16  4.54026E-08     
         9  0.00000E+00  1.17992E-15  3.55271E-15  0.00000E+00  0.00000E+00     
NOTE: Conditional optimal.                                                      
NOTE: Objective = 1347.9166667.                                                 
NOTE: The Interior Point solve time is 0.01 seconds.                            
NOTE: The data set WORK.EX1IPOUT has 8 observations and 10 variables.           
NOTE: The data set WORK.EX1IDOUT has 6 observations and 10 variables.