10 #ifndef _OCRABASE_CASCADE_QP_SOLVER_H_ 11 #define _OCRABASE_CASCADE_QP_SOLVER_H_ 59 static bool has_element(std::vector<const ocra::Function*>& v,
const ocra::Function* e)
61 return std::find(v.begin(),v.end(),e) != v.end();
68 Model::Ptr _innerModel,
69 OneLevelSolver::Ptr _levelSolver,
70 bool _useReducedProblem);
73 void addSolver(OneLevelSolver::Ptr solver,
int level);
76 const std::map<int,OneLevelSolver::Ptr >&
getSolvers();
86 std::shared_ptr<StandardObjectivesAndConstraints>
own_obj;
88 std::map<int,std::shared_ptr<StandardObjectivesAndConstraints> >
std_obj;
95 std::map<int, std::map<int,std::map<Function*,EqualZeroConstraintPtr<LinearFunction> > > > levelConstraints;
96 std::map<int, std::vector<const Function*> > _exclusion_constraints;
97 std::map<int,OneLevelSolver::Ptr > solvermap;
98 std::map<int,std::vector<Task::Ptr> > taskmap;
99 int highest_hierarchy_level;
103 #endif //_OCRABASE_CASCADE_QP_SOLVER_H_ virtual void doConclude()
OneLevelSolver::Ptr levelSolver
virtual void doPrepare(void)
virtual void printValuesAtSolution()
int getNumberOfLevelsAbove(int current_level)
void excludeObjective(int at_level, const ocra::GenericObjective &obj)
Define the internal solver class that can be used in the wOcra controller.
std::shared_ptr< StandardObjectivesAndConstraints > own_obj
CascadeQPSolver(const std::string &_ctrlName, Model::Ptr _innerModel, OneLevelSolver::Ptr _levelSolver, bool _useReducedProblem)
#define DEFINE_CLASS_POINTER_TYPEDEFS(Class)
Optimization-based Robot Controller namespace. a library of classes to write and solve optimization p...
Declaration file of the LinearFunction class.
OneLevelSolver::Ptr getSolver(int level)
Declaration file of the Solver class.
Declaration file of the Constraint class.
virtual void doSolve(void)
std::map< int, std::shared_ptr< StandardObjectivesAndConstraints > > std_obj
void updateHierarchicalContraints(int level)
Declaration file of the structures needed in CascadeQP.
Define base class that can be used as constraints in wOcra controller.
void addTask(Task::Ptr task)
std::vector< int > solverInitialized
void addSolver(OneLevelSolver::Ptr solver, int level)
Define base class that can be used as constraints in wOcra controller.
virtual std::string toString()
Declaration file of the QuadraticFunction class.
const std::map< int, OneLevelSolver::Ptr > & getSolvers()