mirror of https://github.com/CGAL/cgal
parent
b53a562e89
commit
04b0a2c48a
|
|
@ -4,6 +4,8 @@ namespace CGAL {
|
||||||
/// @{
|
/// @{
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
|
\tparam LinearProgram a model of `LinearProgram`.
|
||||||
|
|
||||||
This function writes a linear program to an output stream (in
|
This function writes a linear program to an output stream (in
|
||||||
`MPSFormat`). The time
|
`MPSFormat`). The time
|
||||||
complexity is \f$ \Theta (mn)\f$, even if the program is very sparse.
|
complexity is \f$ \Theta (mn)\f$, even if the program is very sparse.
|
||||||
|
|
@ -12,18 +14,9 @@ It writes the linear program `lp` to `out` in
|
||||||
`MPSFormat`. The name of the program will be the one provided
|
`MPSFormat`. The name of the program will be the one provided
|
||||||
by `problem_name`.
|
by `problem_name`.
|
||||||
|
|
||||||
Requirements
|
\cgalHeading{Requirements}
|
||||||
--------------
|
|
||||||
|
|
||||||
Output operators are defined for all entry types of `lp`.
|
Output operators are defined for all entry types of `lp`.
|
||||||
|
|
||||||
Example
|
|
||||||
--------------
|
|
||||||
|
|
||||||
\ref QP_solver/print_first_lp.cpp
|
|
||||||
|
|
||||||
\sa The concept `LinearProgram`
|
|
||||||
|
|
||||||
*/
|
*/
|
||||||
template <LinearProgram>
|
template <LinearProgram>
|
||||||
void print_linear_program
|
void print_linear_program
|
||||||
|
|
@ -32,6 +25,8 @@ const std::string& problem_name = std::string("MY_MPS"));
|
||||||
|
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
|
\tparam NonnegativeLinearProgram a model of `NonnegativeLinearProgram`
|
||||||
|
|
||||||
This function writes a nonnegative linear program to an output stream
|
This function writes a nonnegative linear program to an output stream
|
||||||
(in `MPSFormat`). The time
|
(in `MPSFormat`). The time
|
||||||
complexity is \f$ \Theta (mn)\f$, even if the program is very sparse.
|
complexity is \f$ \Theta (mn)\f$, even if the program is very sparse.
|
||||||
|
|
@ -40,18 +35,9 @@ Writes the nonnegative linear program `lp` to `out` in
|
||||||
`MPSFormat`. The name of the program will be the one provided
|
`MPSFormat`. The name of the program will be the one provided
|
||||||
by `problem_name`.
|
by `problem_name`.
|
||||||
|
|
||||||
Requirements
|
\cgalHeading{Requirements}
|
||||||
--------------
|
|
||||||
|
|
||||||
Output operators are defined for all entry types of `lp`.
|
Output operators are defined for all entry types of `lp`.
|
||||||
|
|
||||||
Example
|
|
||||||
--------------
|
|
||||||
|
|
||||||
\ref QP_solver/print_first_nonnegative_lp.cpp
|
|
||||||
|
|
||||||
\sa The concept `NonnegativeLinearProgram`
|
|
||||||
|
|
||||||
*/
|
*/
|
||||||
template <NonnegativeLinearProgram>
|
template <NonnegativeLinearProgram>
|
||||||
void print_nonnegative_linear_program
|
void print_nonnegative_linear_program
|
||||||
|
|
@ -60,6 +46,8 @@ const std::string& problem_name = std::string("MY_MPS"));
|
||||||
|
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
|
\tparam NonnegativeQuadraticProgram a model of `NonnegativeQuadraticProgram`
|
||||||
|
|
||||||
This function writes a nonnegative quadratic program
|
This function writes a nonnegative quadratic program
|
||||||
to an output stream (in `MPSFormat`). The time
|
to an output stream (in `MPSFormat`). The time
|
||||||
complexity is \f$ \Theta (n^2 + mn)\f$, even if the program is very sparse.
|
complexity is \f$ \Theta (n^2 + mn)\f$, even if the program is very sparse.
|
||||||
|
|
@ -68,18 +56,9 @@ Writes the nonnegative quadratic program `qp` to `out` in
|
||||||
`MPSFormat`. The name of the program will be the one provided
|
`MPSFormat`. The name of the program will be the one provided
|
||||||
by `problem_name`.
|
by `problem_name`.
|
||||||
|
|
||||||
Requirements
|
\cgalHeading{Requirements}
|
||||||
--------------
|
|
||||||
|
|
||||||
Output operators are defined for all entry types of `qp`.
|
Output operators are defined for all entry types of `qp`.
|
||||||
|
|
||||||
Example
|
|
||||||
--------------
|
|
||||||
|
|
||||||
\ref QP_solver/print_first_nonnegative_qp.cpp
|
|
||||||
|
|
||||||
\sa The concept `NonnegativeQuadraticProgram`
|
|
||||||
|
|
||||||
*/
|
*/
|
||||||
template <NonnegativeQuadraticProgram>
|
template <NonnegativeQuadraticProgram>
|
||||||
void print_nonnegative_quadratic_program
|
void print_nonnegative_quadratic_program
|
||||||
|
|
@ -88,6 +67,9 @@ const std::string& problem_name = std::string("MY_MPS"));
|
||||||
|
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
|
\tparam QuadraticProgram a model of `QuadraticProgram`
|
||||||
|
|
||||||
|
|
||||||
This function writes a quadratic program to an output stream (in
|
This function writes a quadratic program to an output stream (in
|
||||||
`MPSFormat`). The time complexity is \f$ \Theta (n^2 + mn)\f$, even
|
`MPSFormat`). The time complexity is \f$ \Theta (n^2 + mn)\f$, even
|
||||||
if the program is very sparse.
|
if the program is very sparse.
|
||||||
|
|
@ -95,17 +77,9 @@ if the program is very sparse.
|
||||||
Writes the quadratic program `qp` to `out` in `MPSFormat`.
|
Writes the quadratic program `qp` to `out` in `MPSFormat`.
|
||||||
The name of the program will be the one provided by `problem_name`.
|
The name of the program will be the one provided by `problem_name`.
|
||||||
|
|
||||||
Requirements
|
\cgalHeading{Requirements}
|
||||||
--------------
|
|
||||||
|
|
||||||
Output operators are defined for all entry types of `qp`.
|
Output operators are defined for all entry types of `qp`.
|
||||||
|
|
||||||
Example
|
|
||||||
--------------
|
|
||||||
|
|
||||||
\ref QP_solver/print_first_qp.cpp
|
|
||||||
|
|
||||||
\sa The concept `QuadraticProgram`
|
|
||||||
*/
|
*/
|
||||||
template <QuadraticProgram>
|
template <QuadraticProgram>
|
||||||
void print_quadratic_program
|
void print_quadratic_program
|
||||||
|
|
@ -118,10 +92,10 @@ This function solves a linear program, using some exact
|
||||||
Integral Domain `ET` for its computations. Various
|
Integral Domain `ET` for its computations. Various
|
||||||
options may be provided, see `Quadratic_program_options`.
|
options may be provided, see `Quadratic_program_options`.
|
||||||
|
|
||||||
Requirements
|
\tparam LinearProgram a model of `LinearProgram` such as `Quadratic_program<NT>`,
|
||||||
--------------
|
`Quadratic_program_from_mps<NT>`, or `Linear_program_from_iterators<A_it, B_it, R_it, FL_it, L_it, FU_it, U_it, C_it>`
|
||||||
|
|
||||||
`ET` is a model of the concepts `IntegralDomain` and
|
\tparam ET a model of the concepts `IntegralDomain` and
|
||||||
`RealEmbeddable`; it must
|
`RealEmbeddable`; it must
|
||||||
be an exact type, and all entries of `qp` are convertible to
|
be an exact type, and all entries of `qp` are convertible to
|
||||||
`ET`.
|
`ET`.
|
||||||
|
|
@ -144,15 +118,6 @@ factor. For maximum efficiency, it is advisable to define the macros
|
||||||
\returns the solution of the linear program `lp`, solved
|
\returns the solution of the linear program `lp`, solved
|
||||||
with exact number type `ET`.
|
with exact number type `ET`.
|
||||||
|
|
||||||
Example
|
|
||||||
--------------
|
|
||||||
|
|
||||||
\ref QP_solver/first_lp.cpp
|
|
||||||
|
|
||||||
\sa `Quadratic_program<NT>`
|
|
||||||
\sa `Quadratic_program_from_mps<NT>`
|
|
||||||
\sa `Linear_program_from_iterators<A_it, B_it, R_it, FL_it, L_it, FU_it, U_it, C_it>`
|
|
||||||
|
|
||||||
*/
|
*/
|
||||||
template <LinearProgram, ET>
|
template <LinearProgram, ET>
|
||||||
Quadratic_program_solution<ET> solve_linear_program
|
Quadratic_program_solution<ET> solve_linear_program
|
||||||
|
|
@ -165,10 +130,10 @@ This function solves a nonnegative linear program, using some exact
|
||||||
Integral Domain `ET` for its computations. Various
|
Integral Domain `ET` for its computations. Various
|
||||||
options may be provided, see `Quadratic_program_options`.
|
options may be provided, see `Quadratic_program_options`.
|
||||||
|
|
||||||
Requirements
|
\tparam NonnegativeQuadraticProgram a model of `NonnegativeQuadraticProgram` such as
|
||||||
--------------
|
`Quadratic_program<NT>`, `Quadratic_program_from_mps<NT>`, or `Nonnegative_quadratic_program_from_iterators<A_it, B_it, R_it, D_it, C_it>`.
|
||||||
|
|
||||||
`ET` is a model of the concepts `IntegralDomain` and
|
\tparam ET is a model of the concepts `IntegralDomain` and
|
||||||
`RealEmbeddable`; it must
|
`RealEmbeddable`; it must
|
||||||
be an exact type, and all entries of `qp` are convertible to
|
be an exact type, and all entries of `qp` are convertible to
|
||||||
`ET`.
|
`ET`.
|
||||||
|
|
@ -191,16 +156,6 @@ factor. For maximum efficiency, it is advisable to define the macros
|
||||||
\returns the solution of the nonnegative linear program `lp`, solved
|
\returns the solution of the nonnegative linear program `lp`, solved
|
||||||
with exact number type `ET`.
|
with exact number type `ET`.
|
||||||
|
|
||||||
Example
|
|
||||||
--------------
|
|
||||||
|
|
||||||
\ref QP_solver/first_nonnegative_lp.cpp
|
|
||||||
|
|
||||||
The models of \ref NonnegativeLinearProgram\:
|
|
||||||
\sa `Quadratic_program<NT>`
|
|
||||||
\sa `Quadratic_program_from_mps<NT>`
|
|
||||||
\sa `Nonnegative_linear_program_from_iterators<A_it, B_it, R_it, C_it>`
|
|
||||||
|
|
||||||
*/
|
*/
|
||||||
template <NonnegativeLinearProgram, ET>
|
template <NonnegativeLinearProgram, ET>
|
||||||
Quadratic_program_solution<ET> solve_nonnegative_linear_program
|
Quadratic_program_solution<ET> solve_nonnegative_linear_program
|
||||||
|
|
@ -213,10 +168,10 @@ This function solves a nonnegative quadratic program, using some exact
|
||||||
Integral Domain `ET` for its computations. Various
|
Integral Domain `ET` for its computations. Various
|
||||||
options may be provided, see `Quadratic_program_options`.
|
options may be provided, see `Quadratic_program_options`.
|
||||||
|
|
||||||
Requirements
|
\tparam NonnegativeQuadraticProgram a model of `NonnegativeQuadraticProgram` such as
|
||||||
--------------
|
`Quadratic_program<NT>`, `Quadratic_program_from_mps<NT>`, or `Nonnegative_quadratic_program_from_iterators<A_it, B_it, R_it, D_it, C_it>`.
|
||||||
|
|
||||||
`ET` is a model of the concepts `IntegralDomain` and
|
\tparam ET a model of the concepts `IntegralDomain` and
|
||||||
`RealEmbeddable`; it must
|
`RealEmbeddable`; it must
|
||||||
be an exact type, and all entries of `qp` are convertible to
|
be an exact type, and all entries of `qp` are convertible to
|
||||||
`ET`.
|
`ET`.
|
||||||
|
|
@ -239,15 +194,6 @@ factor. For maximum efficiency, it is advisable to define the macros
|
||||||
\returns the solution of the nonnegative quadratic program `qp`, solved
|
\returns the solution of the nonnegative quadratic program `qp`, solved
|
||||||
with exact number type `ET`.
|
with exact number type `ET`.
|
||||||
|
|
||||||
Example
|
|
||||||
--------------
|
|
||||||
|
|
||||||
\ref QP_solver/first_nonnegative_qp.cpp
|
|
||||||
|
|
||||||
The models of \ref ::NonnegativeQuadraticProgram\:
|
|
||||||
\sa `Quadratic_program<NT>`
|
|
||||||
\sa `Quadratic_program_from_mps<NT>`
|
|
||||||
\sa `Nonnegative_quadratic_program_from_iterators<A_it, B_it, R_it, D_it, C_it>`
|
|
||||||
*/
|
*/
|
||||||
template <NonnegativeQuadraticProgram, ET>
|
template <NonnegativeQuadraticProgram, ET>
|
||||||
Quadratic_program_solution<ET> solve_nonnegative_quadratic_program
|
Quadratic_program_solution<ET> solve_nonnegative_quadratic_program
|
||||||
|
|
@ -260,10 +206,11 @@ This function solves a quadratic program, using some exact
|
||||||
Integral Domain `ET` for its computations. Various
|
Integral Domain `ET` for its computations. Various
|
||||||
options may be provided, see `Quadratic_program_options`.
|
options may be provided, see `Quadratic_program_options`.
|
||||||
|
|
||||||
Requirements
|
|
||||||
--------------
|
|
||||||
|
|
||||||
`ET` is a model of the concepts `IntegralDomain` and
|
\tparam NonnegativeQuadraticProgram a model of `NonnegativeQuadraticProgram` such as
|
||||||
|
`Quadratic_program<NT>`, `Quadratic_program_from_mps<NT>`, or `Nonnegative_quadratic_program_from_iterators<A_it, B_it, R_it, D_it, C_it>`.
|
||||||
|
|
||||||
|
\tparam ET is a model of the concepts `IntegralDomain` and
|
||||||
`RealEmbeddable`; it must
|
`RealEmbeddable`; it must
|
||||||
be an exact type, and all entries of `qp` are convertible to
|
be an exact type, and all entries of `qp` are convertible to
|
||||||
`ET`.
|
`ET`.
|
||||||
|
|
@ -286,16 +233,6 @@ factor. For maximum efficiency, it is advisable to define the macros
|
||||||
\returns the solution of the quadratic program `qp`, solved
|
\returns the solution of the quadratic program `qp`, solved
|
||||||
with exact number type `ET`.
|
with exact number type `ET`.
|
||||||
|
|
||||||
Example
|
|
||||||
--------------
|
|
||||||
|
|
||||||
\ref QP_solver/first_qp.cpp
|
|
||||||
|
|
||||||
The models of \ref QuadraticProgram\:
|
|
||||||
\sa `Quadratic_program<NT>`
|
|
||||||
\sa `Quadratic_program_from_mps<NT>`
|
|
||||||
\sa `Quadratic_program_from_iterators<A_it, B_it, R_it, FL_it, L_it, FU_it, U_it, D_it, C_it>`
|
|
||||||
|
|
||||||
*/
|
*/
|
||||||
template <QuadraticProgram, ET>
|
template <QuadraticProgram, ET>
|
||||||
Quadratic_program_solution<ET> solve_quadratic_program
|
Quadratic_program_solution<ET> solve_quadratic_program
|
||||||
|
|
|
||||||
|
|
@ -57,8 +57,7 @@ namespace CGAL {
|
||||||
\cgalModels `QuadraticProgram`
|
\cgalModels `QuadraticProgram`
|
||||||
\cgalModels `LinearProgram`
|
\cgalModels `LinearProgram`
|
||||||
|
|
||||||
Example
|
\cgalHeading{Example}
|
||||||
--------------
|
|
||||||
|
|
||||||
\ref QP_solver/first_lp_from_iterators.cpp
|
\ref QP_solver/first_lp_from_iterators.cpp
|
||||||
|
|
||||||
|
|
@ -113,8 +112,7 @@ public:
|
||||||
|
|
||||||
\returns an instance of `Linear_program_from_iterators<A_it, B_it, R_it, FL_it, L_it, FU_it, U_it, C_it>`, constructed from the given iterators.
|
\returns an instance of `Linear_program_from_iterators<A_it, B_it, R_it, FL_it, L_it, FU_it, U_it, C_it>`, constructed from the given iterators.
|
||||||
|
|
||||||
Example
|
\cgalHeading{Example}
|
||||||
--------------
|
|
||||||
|
|
||||||
The following example demonstrates the typical usage of makers
|
The following example demonstrates the typical usage of makers
|
||||||
with the simpler function `make_nonnegative_linear_program_from_iterators()`.
|
with the simpler function `make_nonnegative_linear_program_from_iterators()`.
|
||||||
|
|
@ -160,8 +158,7 @@ make_linear_program_from_iterators (
|
||||||
\returns an instance of `Nonnegative_linear_program_from_iterators<A_it, B_it, R_it, C_it>`, constructed from the given iterators.
|
\returns an instance of `Nonnegative_linear_program_from_iterators<A_it, B_it, R_it, C_it>`, constructed from the given iterators.
|
||||||
|
|
||||||
|
|
||||||
Example
|
\cgalHeading{Example}
|
||||||
--------------
|
|
||||||
|
|
||||||
`QP_solver/solve_convex_hull_containment_lp2.h`
|
`QP_solver/solve_convex_hull_containment_lp2.h`
|
||||||
|
|
||||||
|
|
@ -198,8 +195,7 @@ make_nonnegative_linear_program_from_iterators (
|
||||||
`Nonnegative_quadratic_program_from_iterators<A_it, B_it, R_it, D_it,C_it>`,
|
`Nonnegative_quadratic_program_from_iterators<A_it, B_it, R_it, D_it,C_it>`,
|
||||||
constructed from the given iterators.
|
constructed from the given iterators.
|
||||||
|
|
||||||
Example
|
\cgalHeading{Example}
|
||||||
--------------
|
|
||||||
|
|
||||||
The following example demonstrates the typical usage of makers
|
The following example demonstrates the typical usage of makers
|
||||||
with the simpler function `make_nonnegative_linear_program_from_iterators()`.
|
with the simpler function `make_nonnegative_linear_program_from_iterators()`.
|
||||||
|
|
@ -240,8 +236,7 @@ make_nonnegative_quadratic_program_from_iterators (
|
||||||
|
|
||||||
\returns an instance of `Quadratic_program_from_iterators<A_it, B_it, R_it, FL_it, L_it, FU_it, U_it, D_it, C_it>`, constructed from the given iterators.
|
\returns an instance of `Quadratic_program_from_iterators<A_it, B_it, R_it, FL_it, L_it, FU_it, U_it, D_it, C_it>`, constructed from the given iterators.
|
||||||
|
|
||||||
Example
|
\cgalHeading{Example}
|
||||||
--------------
|
|
||||||
|
|
||||||
The following example demonstrates the typical usage of makers
|
The following example demonstrates the typical usage of makers
|
||||||
with the simpler function `make_nonnegative_linear_program_from_iterators()`.
|
with the simpler function `make_nonnegative_linear_program_from_iterators()`.
|
||||||
|
|
@ -330,8 +325,7 @@ make_quadratic_program_from_iterators (
|
||||||
\cgalModels `NonnegativeQuadraticProgram`
|
\cgalModels `NonnegativeQuadraticProgram`
|
||||||
\cgalModels `NonnegativeLinearProgram`
|
\cgalModels `NonnegativeLinearProgram`
|
||||||
|
|
||||||
Example
|
\cgalHeading{Example}
|
||||||
--------------
|
|
||||||
|
|
||||||
\ref QP_solver/first_nonnegative_lp_from_iterators.cpp
|
\ref QP_solver/first_nonnegative_lp_from_iterators.cpp
|
||||||
|
|
||||||
|
|
@ -422,8 +416,7 @@ public:
|
||||||
\cgalModels `QuadraticProgram`
|
\cgalModels `QuadraticProgram`
|
||||||
\cgalModels `NonnegativeQuadraticProgram`
|
\cgalModels `NonnegativeQuadraticProgram`
|
||||||
|
|
||||||
Example
|
\cgalHeading{Example}
|
||||||
--------------
|
|
||||||
|
|
||||||
\ref QP_solver/first_nonnegative_qp_from_iterators.cpp
|
\ref QP_solver/first_nonnegative_qp_from_iterators.cpp
|
||||||
|
|
||||||
|
|
@ -522,8 +515,7 @@ public:
|
||||||
|
|
||||||
\cgalModels `QuadraticProgram`
|
\cgalModels `QuadraticProgram`
|
||||||
|
|
||||||
Example
|
\cgalHeading{Example}
|
||||||
--------------
|
|
||||||
|
|
||||||
\ref QP_solver/first_qp_from_iterators.cpp
|
\ref QP_solver/first_qp_from_iterators.cpp
|
||||||
|
|
||||||
|
|
@ -630,8 +622,7 @@ public:
|
||||||
\cgalModels `NonnegativeQuadraticProgram`
|
\cgalModels `NonnegativeQuadraticProgram`
|
||||||
\cgalModels `NonnegativeLinearProgram`
|
\cgalModels `NonnegativeLinearProgram`
|
||||||
|
|
||||||
Example
|
\cgalHeading{Example}
|
||||||
--------------
|
|
||||||
|
|
||||||
\ref QP_solver/first_qp_from_mps.cpp
|
\ref QP_solver/first_qp_from_mps.cpp
|
||||||
|
|
||||||
|
|
@ -854,8 +845,7 @@ namespace CGAL {
|
||||||
\cgalModels `NonnegativeQuadraticProgram`
|
\cgalModels `NonnegativeQuadraticProgram`
|
||||||
\cgalModels `NonnegativeLinearProgram`
|
\cgalModels `NonnegativeLinearProgram`
|
||||||
|
|
||||||
Example
|
\cgalHeading{Example}
|
||||||
--------------
|
|
||||||
|
|
||||||
\ref QP_solver/first_qp.cpp
|
\ref QP_solver/first_qp.cpp
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -15,8 +15,7 @@ options referring to
|
||||||
</OL>
|
</OL>
|
||||||
The idea is that this list grows in the future.
|
The idea is that this list grows in the future.
|
||||||
|
|
||||||
Operations
|
\cgalHeading{Operations}
|
||||||
--------------
|
|
||||||
|
|
||||||
Here we just have set/get pairs for any option type.
|
Here we just have set/get pairs for any option type.
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -36,13 +36,11 @@ the four functions
|
||||||
`solve_nonnegative_quadratic_program`, and
|
`solve_nonnegative_quadratic_program`, and
|
||||||
`solve_nonnegative_linear_program`.
|
`solve_nonnegative_linear_program`.
|
||||||
|
|
||||||
Example
|
\cgalHeading{Example}
|
||||||
--------------
|
|
||||||
|
|
||||||
\ref QP_solver/first_qp.cpp
|
\ref QP_solver/first_qp.cpp
|
||||||
|
|
||||||
Terminology
|
\cgalHeading{Terminology}
|
||||||
--------------
|
|
||||||
|
|
||||||
If there is no \f$ \qpx\f$ that satisfies all the (in)equalities,
|
If there is no \f$ \qpx\f$ that satisfies all the (in)equalities,
|
||||||
the program is called <I>infeasible</I>, otherwise, it is <I>feasible</I>,
|
the program is called <I>infeasible</I>, otherwise, it is <I>feasible</I>,
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue