35 #include <qpOASES.hpp> 45 real_t H[2*2] = { 1.0, 0.0, 0.0, 0.5 };
68 example.
init( H,g,lb,ub, nWSR,0 );
81 printf(
"stat = %e\nfeas = %e\ncmpl = %e\n", stat,feas,cmpl );
90 example.
hotstart( g_new,lb_new,ub_new, nWSR,0 );
96 printf(
"\nxOpt = [ %e, %e ]; objVal = %e\n\n", xOpt[0],xOpt[1],example.
getObjVal() );
100 printf(
"stat = %e\nfeas = %e\ncmpl = %e\n", stat,feas,cmpl );
returnValue getPrimalSolution(real_t *const xOpt) const
#define USING_NAMESPACE_QPOASES
Implements the online active set strategy for box-constrained QPs.
returnValue init(const real_t *const _H, const real_t *const _g, const real_t *const _lb, const real_t *const _ub, int &nWSR, const real_t *const yOpt=0, real_t *const cputime=0)
returnValue setOptions(const Options &_options)
returnValue hotstart(const real_t *const g_new, const real_t *const lb_new, const real_t *const ub_new, int &nWSR, real_t *const cputime)
returnValue getDualSolution(real_t *const yOpt) const
Provides a generic way to set and pass user-specified options.
Provides additional tools for analysing QP solutions.
#define QPOASES_TEST_FOR_TOL(x, tol)
real_t getKktViolation(QProblemB *const qp, real_t *const maxStat=0, real_t *const maxFeas=0, real_t *const maxCmpl=0) const
int enableCholeskyRefactorisation
SubjectToStatus initialStatusBounds