16.8 The Solution File Format

MOSEK can output solutions to a text file:

  • basis solution file (extension .bas) if the problem is optimized using the simplex optimizer or basis identification is performed,

  • interior solution file (extension .sol) if a problem is optimized using the interior-point optimizer and no basis identification is required,

  • integer solution file (extension .int) if the problem is solved with the mixed-integer optimizer.

All solution files have the format:

NAME                : <problem name>
PROBLEM STATUS      : <status of the problem>
SOLUTION STATUS     : <status of the solution>
OBJECTIVE NAME      : <name of the objective function>
PRIMAL OBJECTIVE    : <primal objective value corresponding to the solution>
DUAL OBJECTIVE      : <dual objective value corresponding to the solution>

CONSTRAINTS
INDEX  NAME     AT ACTIVITY    LOWER LIMIT   UPPER LIMIT   DUAL LOWER   DUAL UPPER
?      <name>   ?? <a value>   <a value>     <a value>     <a value>    <a value>

AFFINE CONIC CONSTRAINTS
INDEX  NAME     I          ACTIVITY    DUAL
?      <name>   <a value>  <a value>   <a value>

VARIABLES
INDEX  NAME     AT ACTIVITY    LOWER LIMIT   UPPER LIMIT   DUAL LOWER   DUAL UPPER    [CONIC DUAL]
?      <name>   ?? <a value>   <a value>     <a value>     <a value>    <a value>     [<a value>]

SYMMETRIC MATRIX VARIABLES
INDEX  NAME     I           J             PRIMAL        DUAL
?      <name>   <a value>   <a value>     <a value>     <a value>

The fields ?, ?? and <> will be filled with problem and solution specific information as described below. The solution contains sections corresponding to parts of the input. Empty sections may be omitted and fields in [] are optional, depending on what type of problem is solved. The notation below follows the MOSEK naming convention for parts of the solution as defined in the problem specifications in Sec. 12 (Problem Formulation and Solutions).

  • HEADER

    In this section, first the name of the problem is listed and afterwards the problem and solution status are shown. Next the primal and dual objective values are displayed.

  • CONSTRAINTS

    • INDEX: A sequential index assigned to the constraint by MOSEK

    • NAME: The name of the constraint assigned by the user or autogenerated.

    • AT: The status key bkc of the constraint as in Table 16.4.

    • ACTIVITY: the activity xc of the constraint expression.

    • LOWER LIMIT: the lower bound blc of the constraint.

    • UPPER LIMIT: the upper bound buc of the constraint.

    • DUAL LOWER: the dual multiplier slc corresponding to the lower limit on the constraint.

    • DUAL UPPER: the dual multiplier suc corresponding to the upper limit on the constraint.

  • AFFINE CONIC CONSTRAINTS

    • INDEX: A sequential index assigned to the affine expressions by MOSEK

    • NAME: The name of the affine conic constraint assigned by the user or autogenerated.

    • I: The sequential index of the affine expression in the affine conic constraint.

    • ACTIVITY: the activity of the I-th affine expression in the affine conic constraint.

    • DUAL: the dual multiplier doty for the I-th entry in the affine conic constraint.

  • VARIABLES

    • INDEX: A sequential index assigned to the variable by MOSEK

    • NAME: The name of the variable assigned by the user or autogenerated.

    • AT: The status key bkx of the variable as in Table 16.4.

    • ACTIVITY: the value xx of the variable.

    • LOWER LIMIT: the lower bound blx of the variable.

    • UPPER LIMIT: the upper bound bux of the variable.

    • DUAL LOWER: the dual multiplier slx corresponding to the lower limit on the variable.

    • DUAL UPPER: the dual multiplier sux corresponding to the upper limit on the variable.

    • CONIC DUAL: the dual multiplier skx corresponding to a conic variable (deprecated).

  • SYMMETRIC MATRIX VARIABLES

    • INDEX: A sequential index assigned to each symmetric matrix entry by MOSEK

    • NAME: The name of the symmetric matrix variable assigned by the user or autogenerated.

    • I: The row index in the symmetric matrix variable.

    • J: The column index in the symmetric matrix variable.

    • PRIMAL: the value of barx for the (I, J)-th entry in the symmetric matrix variable.

    • DUAL: the dual multiplier bars for the (I, J)-th entry in the symmetric matrix variable.

Table 16.4 Status keys.

Status key

Interpretation

UN

Unknown status

BS

Is basic

SB

Is superbasic

LL

Is at the lower limit (bound)

UL

Is at the upper limit (bound)

EQ

Lower limit is identical to upper limit

**

Is infeasible i.e. the lower limit is greater than the upper limit.

Example.

Below is an example of a solution file.

Listing 16.6 An example of .sol file. Click here to download.
NAME                :
PROBLEM STATUS      : PRIMAL_AND_DUAL_FEASIBLE
SOLUTION STATUS     : OPTIMAL
OBJECTIVE NAME      : OBJ
PRIMAL OBJECTIVE    : 0.70571049347734
DUAL OBJECTIVE      : 0.70571048919757

CONSTRAINTS
INDEX      NAME           AT ACTIVITY                 LOWER LIMIT        UPPER LIMIT        DUAL LOWER               DUAL UPPER

AFFINE CONIC CONSTRAINTS
INDEX      NAME           I          ACTIVITY                 DUAL
0          A1             0          1.0000000009656          0.54475821296644
1          A1             1          0.50000000152223         0.32190455246225
2          A2             0          0.25439922724695         0.4552417870329
3          A2             1          0.17988741850378         -0.32190455246178
4          A2             2          0.17988741850378         -0.32190455246178

VARIABLES
INDEX      NAME           AT ACTIVITY                 LOWER LIMIT        UPPER LIMIT        DUAL LOWER               DUAL UPPER
0          X1             SB 0.25439922724695         NONE               NONE               0                        0
1          X2             SB 0.17988741850378         NONE               NONE               0                        0
2          X3             SB 0.17988741850378         NONE               NONE               0                        0

SYMMETRIC MATRIX VARIABLES
INDEX      NAME           I         J         PRIMAL                   DUAL
0          BARX1          0         0         0.21725733689874         1.1333372337141
1          BARX1          1         0         -0.25997257078534        0.67809544651396
2          BARX1          2         0         0.21725733648507         -0.3219045527104
3          BARX1          1         1         0.31108610088839         1.1333372332693
4          BARX1          2         1         -0.25997257078534        0.67809544651435
5          BARX1          2         2         0.21725733689874         1.1333372337145
6          BARX2          0         0         4.8362272828127e-10      0.54475821339698
7          BARX2          1         0         0                        0
8          BARX2          1         1         4.8362272828127e-10      0.54475821339698