Blender V2.61 - r43446

Solver.hpp

Go to the documentation of this file.
00001 /*
00002  * Solver.hpp
00003  *
00004  *  Created on: Jan 8, 2009
00005  *      Author: rubensmits
00006  */
00007 
00008 #ifndef SOLVER_HPP_
00009 #define SOLVER_HPP_
00010 
00011 #include <vector>
00012 #include "eigen_types.hpp"
00013 
00014 namespace iTaSC{
00015 
00016 class Solver{
00017 public:
00018     enum SolverParam {
00019         DLS_QMAX = 0,
00020         DLS_LAMBDA_MAX,
00021         DLS_EPSILON
00022     };
00023     virtual ~Solver(){};
00024 
00025     // gc = grouping of constraint output , 
00026     //      size of vector = nc, alternance of true / false to indicate the grouping of output
00027     virtual bool init(unsigned int nq, unsigned int nc, const std::vector<bool>& gc)=0;
00028     virtual bool solve(const e_matrix& A, const e_vector& Wy, const e_vector& ydot, const e_matrix& Wq, e_vector& qdot, e_scalar& nlcoef)=0;
00029     virtual void setParam(SolverParam param, double value)=0;
00030 };
00031 
00032 }
00033 #endif /* SOLVER_HPP_ */