42 #ifndef QP_SOLVER_RELAXED_H
43 #define QP_SOLVER_RELAXED_H
48 namespace ConstrainedOptPack {
140 {
public:
Unbounded(
const std::string& what_arg) : std::logic_error(what_arg) {}};
144 {
public:
Infeasible(
const std::string& what_arg) : std::logic_error(what_arg) {}};
148 {
public:
InvalidInput(
const std::string& what_arg) : std::logic_error(what_arg) {}};
152 {
public:
TestFailed(
const std::string& what_arg) : std::logic_error(what_arg) {}};
313 ,
const Vector& g,
const MatrixSymOp& G
315 ,
const Vector& dL,
const Vector& dU
317 ,
const Vector& eL,
const Vector& eU
322 ,VectorMutable* mu, VectorMutable* Ed
323 ,VectorMutable* lambda, VectorMutable* Fd
333 ,
const Vector& g,
const MatrixSymOp& G
335 ,
const Vector& dL,
const Vector& dU
337 ,
const Vector& eL,
const Vector& eU
341 ,VectorMutable* mu, VectorMutable* Ed
351 ,
const Vector& g,
const MatrixSymOp& G
353 ,
const Vector& dL,
const Vector& dU
358 ,VectorMutable* lambda, VectorMutable* Fd
370 ,
const Vector& g,
const MatrixSymOp& G
371 ,
const Vector& dL,
const Vector& dU
390 ,
const Vector& g,
const MatrixSymOp& G
392 ,
const Vector* dL,
const Vector* dU
394 ,
const Vector* eL,
const Vector* eU
399 ,VectorMutable* mu, VectorMutable* Ed
400 ,VectorMutable* lambda, VectorMutable* Fd
451 ,
const Vector& g,
const MatrixSymOp& G
453 ,
const Vector* dL,
const Vector* dU
455 ,
const Vector* eL,
const Vector* eU
460 ,
const Vector* mu,
const Vector* Ed
461 ,
const Vector* lambda,
const Vector* Fd
482 ,
const Vector& g,
const MatrixSymOp& G
484 ,
const Vector* dL,
const Vector* dU
486 ,
const Vector* eL,
const Vector* eU
491 ,VectorMutable* lambda
515 ,
const Vector* mu,
const Vector* Ed
516 ,
const Vector* lambda,
const Vector* Fd
532 ,
const Vector& g,
const MatrixSymOp& G
534 ,
const Vector* dL,
const Vector* dU
536 ,
const Vector* eL,
const Vector* eU
541 ,VectorMutable* mu, VectorMutable* Ed
542 ,VectorMutable* lambda, VectorMutable* Fd
551 #endif // QP_SOLVER_RELAXED_H
ERunTests
Enumeration for if to run internal tests or not.
Solves Quadratic Programs (QPs) of several different forms while allowing a relaxation of the constra...
virtual QPSolverStats::ESolutionType imp_solve_qp(std::ostream *out, EOutputLevel olevel, ERunTests test_what, const Vector &g, const MatrixSymOp &G, value_type etaL, const Vector *dL, const Vector *dU, const MatrixOp *E, BLAS_Cpp::Transp trans_E, const Vector *b, const Vector *eL, const Vector *eU, const MatrixOp *F, BLAS_Cpp::Transp trans_F, const Vector *f, value_type *obj_d, value_type *eta, VectorMutable *d, VectorMutable *nu, VectorMutable *mu, VectorMutable *Ed, VectorMutable *lambda, VectorMutable *Fd)=0
Subclasses are to override this to implement the QP algorithm.
virtual ~QPSolverRelaxed()
static void print_qp_output(const value_type infinite_bound, std::ostream *out, EOutputLevel olevel, const value_type *obj_d, const value_type *eta, const Vector *d, const Vector *nu, const Vector *mu, const Vector *Ed, const Vector *lambda, const Vector *Fd)
Utility (static) function for printing the output input/output arguments after the QP solver is run...
static void print_qp_input(const value_type infinite_bound, std::ostream *out, EOutputLevel olevel, const Vector &g, const MatrixSymOp &G, value_type etaL, const Vector *dL, const Vector *dU, const MatrixOp *E, BLAS_Cpp::Transp trans_E, const Vector *b, const Vector *eL, const Vector *eU, const MatrixOp *F, BLAS_Cpp::Transp trans_F, const Vector *f, value_type *eta, VectorMutable *d, VectorMutable *nu, VectorMutable *mu, VectorMutable *lambda)
Utility (static) function for printing the input input/output arguments before the QP solver is run...
TestFailed(const std::string &what_arg)
Thrown if the QP is unbounded.
Unbounded(const std::string &what_arg)
Class for storing statistics about a run of a (active set?) QP solver.
virtual QPSolverStats::ESolutionType solve_qp(std::ostream *out, EOutputLevel olevel, ERunTests test_what, const Vector &g, const MatrixSymOp &G, value_type etaL, const Vector &dL, const Vector &dU, const MatrixOp &E, BLAS_Cpp::Transp trans_E, const Vector &b, const Vector &eL, const Vector &eU, const MatrixOp &F, BLAS_Cpp::Transp trans_F, const Vector &f, value_type *obj_d, value_type *eta, VectorMutable *d, VectorMutable *nu, VectorMutable *mu, VectorMutable *Ed, VectorMutable *lambda, VectorMutable *Fd)
Solve the QP.
static void validate_input(const value_type infinite_bound, const Vector &g, const MatrixSymOp &G, value_type etaL, const Vector *dL, const Vector *dU, const MatrixOp *E, BLAS_Cpp::Transp trans_E, const Vector *b, const Vector *eL, const Vector *eU, const MatrixOp *F, BLAS_Cpp::Transp trans_F, const Vector *f, const value_type *obj_d, const value_type *eta, const Vector *d, const Vector *nu, const Vector *mu, const Vector *Ed, const Vector *lambda, const Vector *Fd)
This is a (static) function that is used as a utility to validate the input arguments to solve_qp()...
EOutputLevel
Enumeration for the amount of output to create from solve_qp().
AbstractLinAlgPack::value_type value_type
Infeasible(const std::string &what_arg)
STANDARD_MEMBER_COMPOSITION_MEMBERS(value_type, infinite_bound)
Set the scalar that will be used to identigy infinite bounds.
virtual QPSolverStats get_qp_stats() const =0
Get the statistics of the last QP solved.
ESolutionType
Enumeration for the type of point returned from solve_qp(...).
Thrown if the QP is infeasible.
virtual void release_memory()=0
Release any memory that is being used.