tsid  1.8.0
Efficient Task Space Inverse Dynamics for Multi-body Systems based on Pinocchio
fwd.hpp
Go to the documentation of this file.
1 //
2 // Copyright (c) 2017 CNRS
3 //
4 // This file is part of tsid
5 // tsid is free software: you can redistribute it
6 // and/or modify it under the terms of the GNU Lesser General Public
7 // License as published by the Free Software Foundation, either version
8 // 3 of the License, or (at your option) any later version.
9 // tsid is distributed in the hope that it will be
10 // useful, but WITHOUT ANY WARRANTY; without even the implied warranty
11 // of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 // General Lesser Public License for more details. You should have
13 // received a copy of the GNU Lesser General Public License along with
14 // tsid If not, see
15 // <http://www.gnu.org/licenses/>.
16 //
17 
18 #ifndef __invdyn_solvers_fwd_hpp__
19 #define __invdyn_solvers_fwd_hpp__
20 
21 #include <memory>
22 
23 #include "tsid/config.hh"
24 #include "tsid/math/fwd.hpp"
26 #include <pinocchio/container/aligned-vector.hpp>
27 
28 #define DEFAULT_HESSIAN_REGULARIZATION 1e-8
29 
30 namespace tsid {
31 namespace solvers {
32 
36 enum TSID_DLLAPI SolverHQP {
39  SOLVER_HQP_EIQUADPROG_RT = 2
40 #ifdef TSID_QPMAD_FOUND
41  ,
42  SOLVER_HQP_QPMAD
43 #endif
44 #ifdef TSID_WITH_PROXSUITE
45  ,
46  SOLVER_HQP_PROXQP
47 #endif
48 #ifdef TSID_WITH_OSQP
49  ,
50  SOLVER_HQP_OSQP
51 #endif
52 #ifdef QPOASES_FOUND
53  ,
54  SOLVER_HQP_OASES
55 #endif
56 };
57 
61 enum TSID_DLLAPI HQPStatus {
67  HQP_STATUS_ERROR = 4
68 };
69 
70 class HQPOutput;
71 
73 
74 template <int nVars, int nEqCon, int nIneqCon>
76 
77 template <typename T1, typename T2>
78 class aligned_pair {
79  public:
80  EIGEN_MAKE_ALIGNED_OPERATOR_NEW
81 
82  aligned_pair(const T1& t1, const T2& t2) : first(t1), second(t2) {}
83 
84  T1 first;
85  T2 second;
86 };
87 
88 template <typename T1, typename T2>
89 inline aligned_pair<T1, T2> make_pair(const T1& t1, const T2& t2) {
90  return aligned_pair<T1, T2>(t1, t2);
91 }
92 
93 typedef pinocchio::container::aligned_vector<
94  aligned_pair<double, std::shared_ptr<math::ConstraintBase> > >
96 typedef pinocchio::container::aligned_vector<
99 typedef pinocchio::container::aligned_vector<ConstraintLevel> HQPData;
100 typedef pinocchio::container::aligned_vector<ConstConstraintLevel> ConstHQPData;
101 
105 
106 } // namespace solvers
107 } // namespace tsid
108 
109 #endif // ifndef __invdyn_solvers_fwd_hpp__
Definition: fwd.hpp:78
T1 first
Definition: fwd.hpp:84
T2 second
Definition: fwd.hpp:85
EIGEN_MAKE_ALIGNED_OPERATOR_NEW aligned_pair(const T1 &t1, const T2 &t2)
Definition: fwd.hpp:82
#define TSID_DLLAPI
Definition: config.hh:88
QPDataQuadProgTpl< double > QPDataQuadProg
Definition: fwd.hpp:104
QPDataTpl< double > QPData
Definition: fwd.hpp:102
QPDataBaseTpl< double > QPDataBase
Definition: fwd.hpp:103
class TSID_DLLAPI SolverHQuadProgRT
Definition: fwd.hpp:75
pinocchio::container::aligned_vector< aligned_pair< double, std::shared_ptr< const math::ConstraintBase > > > ConstConstraintLevel
Definition: fwd.hpp:98
class TSID_DLLAPI SolverHQPBase
Definition: fwd.hpp:72
pinocchio::container::aligned_vector< ConstraintLevel > HQPData
Definition: fwd.hpp:99
pinocchio::container::aligned_vector< ConstConstraintLevel > ConstHQPData
Definition: fwd.hpp:100
aligned_pair< T1, T2 > make_pair(const T1 &t1, const T2 &t2)
Definition: fwd.hpp:89
pinocchio::container::aligned_vector< aligned_pair< double, std::shared_ptr< math::ConstraintBase > > > ConstraintLevel
Definition: fwd.hpp:95
Definition: constraint-bound.hpp:25
HQP_STATUS_UNBOUNDED
Definition: fwd.hpp:65
HQP_STATUS_UNKNOWN
Definition: fwd.hpp:62
HQP_STATUS_MAX_ITER_REACHED
Definition: fwd.hpp:66
SOLVER_HQP_EIQUADPROG
Definition: fwd.hpp:37
SOLVER_HQP_EIQUADPROG_FAST
Definition: fwd.hpp:38
HQP_STATUS_OPTIMAL
Definition: fwd.hpp:63
HQP_STATUS_INFEASIBLE
Definition: fwd.hpp:64
Definition: solver-qpData.hpp:25