> > ILOG CPLEX File Formats > MPS File Format > Quadratic Objective Information in MPS Files

If you use the ILOG CPLEX barrier optimizer for quadratic programming problems (QPs), then you can specify quadratic objective coefficients in MPS format.

Following the BOUNDS section, a QMATRIX section may be specified. Each line of this section defines one nonzero coefficient of the matrix Q. Each line should contain two variable names (which must have been specified in the COLUMNS section) in Fields 2 and 3, followed by a nonzero coefficient value in Field 4. For each off-diagonal coefficient, two lines must appear: one for the lower triangular element, and one for the upper triangular element. ILOG CPLEX evaluates the quadratic part of the objective function as 0.5 x'Qx, when the coefficients of Q are specified in an MPS file.

For example, consider the following problem:

Minimize 

 

 

 

 

 

 

 

 

 

 

 
1/2 
(a2 
4ab 
7b2) 
subject to 

 

 

 

 

 

 

 

 

 

 

 
 
10 

 

 

 

 

 

 
a, 
 

 

 

 

 

 

 

In MPS format, you may enter the problem in the following way:

NAME          problem
ROWS
 N  obj
 G  c1
COLUMNS
    a         obj                  1   c1                   1
    b         obj                  1   c1                   1
RHS
    rhs       c1                  10
QMATRIX
    a         a                    1
    a         b                    2
    b         a                    2
    b         b                    7
ENDATA