#include <CGAL/QP_models.h>
|
If D=0, the program is a linear program; if the variable bounds are x ≥ 0, we have a nonnegative program.
The program data are read from an input stream in MPSFormat. This is a commonly used format for encoding linear and quadratic programs that is understood by many solvers. All values are expected to be readable into type NT. The constructed program can be further manipulated by using the set-methods below.
| |
The number type of the program entries.
|
| |
reads qp from the input stream in.
|
|
| returns true if and only if an MPS-encoded quadratic program could be extracted from the input stream. | ||
|
| if !qp.is_valid(), this method returns an error message explaining why the input does not conform to the MPSFormat. | ||
|
| |||
returns the name of the j-th variable.
| ||||
|
| |||
returns the index of the variable with name name. If there is no variable with this name, the result is -1. | ||||
|
| |||
returns the name of the i-th constraint.
| ||||
|
| |||
returns the index of the constraint with name name. If there is no constraint with this name, the result is -1. | ||||
|
| returns true if and only if qp is a linear program. | ||
|
| returns true if and only if qp is a nonnegative program. | ||
|
| sets the entry Aij in column j and row i of the constraint matrix A of qp to val. An existing entry is overwritten. qp is enlarged if necessary to accomodate this entry. | ||
|
| sets the entry bi of qp to val. An existing entry is overwritten. qp is enlarged if necessary to accomodate this entry. | ||
|
| |||
sets the entry ⋛ i of qp to rel. CGAL::SMALLER means that the i-th constraint is of type `` ≤ '', CGAL::EQUAL means ``='', and CGAL::LARGER encodes `` ≥ ''. An existing entry is overwritten. qp is enlarged if necessary to accomodate this entry. | ||||
|
| |||
if is_finite, this sets the entry lj of qp to val, otherwise it sets lj to -∞. An existing entry is overwritten. qp is enlarged if necessary to accomodate this entry. | ||||
|
| |||
if is_finite, this sets the entry uj of qp to val, otherwise it sets uj to ∞. An existing entry is overwritten. qp is enlarged if necessary to accomodate this entry. | ||||
|
| sets the entry cj of qp to val. An existing entry is overwritten. qp is enlarged if necessary to accomodate this entry. | ||
|
| sets the entry c0 of qp to val. An existing entry is overwritten. | ||
|
|
sets the entries
2Dij and 2Dji of qp to val. Existing entries are
overwritten. qp is enlarged if necessary to accomodate these entries.
|
QP_solver/first_qp_from_mps.cpp
QP_solver/first_lp_from_mps.cpp
QP_solver/first_nonnegative_qp_from_mps.cpp
QP_solver/first_nonnegative_lp_from_mps.cpp