- 3.0.2 rigid body dynamics module.
inertia_properties.h
Go to the documentation of this file.
1 #ifndef IIT_ROBOT_TESTHYQ_INERTIA_PROPERTIES_H_
2 #define IIT_ROBOT_TESTHYQ_INERTIA_PROPERTIES_H_
3 
4 #include <iit/rbd/rbd.h>
6 #include <iit/rbd/utils.h>
8 
9 #include "declarations.h"
10 
11 namespace iit {
12 namespace TestHyQ {
17 namespace dyn {
18 
20 
21 namespace tpl {
22 
23 template <typename TRAIT>
25  public:
26  EIGEN_MAKE_ALIGNED_OPERATOR_NEW
27 
28  typedef typename TRAIT::Scalar Scalar;
31  typedef typename CoreS::Vector3 Vec3d;
32 
35  const IMatrix& getTensor_trunk() const;
36  const IMatrix& getTensor_LF_hipassembly() const;
37  const IMatrix& getTensor_LF_upperleg() const;
38  const IMatrix& getTensor_LF_lowerleg() const;
39  const IMatrix& getTensor_RF_hipassembly() const;
40  const IMatrix& getTensor_RF_upperleg() const;
41  const IMatrix& getTensor_RF_lowerleg() const;
42  const IMatrix& getTensor_LH_hipassembly() const;
43  const IMatrix& getTensor_LH_upperleg() const;
44  const IMatrix& getTensor_LH_lowerleg() const;
45  const IMatrix& getTensor_RH_hipassembly() const;
46  const IMatrix& getTensor_RH_upperleg() const;
47  const IMatrix& getTensor_RH_lowerleg() const;
48  Scalar getMass_trunk() const;
49  Scalar getMass_LF_hipassembly() const;
50  Scalar getMass_LF_upperleg() const;
51  Scalar getMass_LF_lowerleg() const;
52  Scalar getMass_RF_hipassembly() const;
53  Scalar getMass_RF_upperleg() const;
54  Scalar getMass_RF_lowerleg() const;
55  Scalar getMass_LH_hipassembly() const;
56  Scalar getMass_LH_upperleg() const;
57  Scalar getMass_LH_lowerleg() const;
58  Scalar getMass_RH_hipassembly() const;
59  Scalar getMass_RH_upperleg() const;
60  Scalar getMass_RH_lowerleg() const;
61  const Vec3d& getCOM_trunk() const;
62  const Vec3d& getCOM_LF_hipassembly() const;
63  const Vec3d& getCOM_LF_upperleg() const;
64  const Vec3d& getCOM_LF_lowerleg() const;
65  const Vec3d& getCOM_RF_hipassembly() const;
66  const Vec3d& getCOM_RF_upperleg() const;
67  const Vec3d& getCOM_RF_lowerleg() const;
68  const Vec3d& getCOM_LH_hipassembly() const;
69  const Vec3d& getCOM_LH_upperleg() const;
70  const Vec3d& getCOM_LH_lowerleg() const;
71  const Vec3d& getCOM_RH_hipassembly() const;
72  const Vec3d& getCOM_RH_upperleg() const;
73  const Vec3d& getCOM_RH_lowerleg() const;
74  Scalar getTotalMass() const;
75 
76  private:
77 
78  IMatrix tensor_trunk;
79  IMatrix tensor_LF_hipassembly;
80  IMatrix tensor_LF_upperleg;
81  IMatrix tensor_LF_lowerleg;
82  IMatrix tensor_RF_hipassembly;
83  IMatrix tensor_RF_upperleg;
84  IMatrix tensor_RF_lowerleg;
85  IMatrix tensor_LH_hipassembly;
86  IMatrix tensor_LH_upperleg;
87  IMatrix tensor_LH_lowerleg;
88  IMatrix tensor_RH_hipassembly;
89  IMatrix tensor_RH_upperleg;
90  IMatrix tensor_RH_lowerleg;
91  Vec3d com_trunk;
92  Vec3d com_LF_hipassembly;
93  Vec3d com_LF_upperleg;
94  Vec3d com_LF_lowerleg;
95  Vec3d com_RF_hipassembly;
96  Vec3d com_RF_upperleg;
97  Vec3d com_RF_lowerleg;
98  Vec3d com_LH_hipassembly;
99  Vec3d com_LH_upperleg;
100  Vec3d com_LH_lowerleg;
101  Vec3d com_RH_hipassembly;
102  Vec3d com_RH_upperleg;
103  Vec3d com_RH_lowerleg;
104 };
105 
106 template <typename TRAIT>
108 
109 template <typename TRAIT>
111  return this->tensor_trunk;
112 }
113 template <typename TRAIT>
115  return this->tensor_LF_hipassembly;
116 }
117 template <typename TRAIT>
119  return this->tensor_LF_upperleg;
120 }
121 template <typename TRAIT>
123  return this->tensor_LF_lowerleg;
124 }
125 template <typename TRAIT>
127  return this->tensor_RF_hipassembly;
128 }
129 template <typename TRAIT>
131  return this->tensor_RF_upperleg;
132 }
133 template <typename TRAIT>
135  return this->tensor_RF_lowerleg;
136 }
137 template <typename TRAIT>
139  return this->tensor_LH_hipassembly;
140 }
141 template <typename TRAIT>
143  return this->tensor_LH_upperleg;
144 }
145 template <typename TRAIT>
147  return this->tensor_LH_lowerleg;
148 }
149 template <typename TRAIT>
151  return this->tensor_RH_hipassembly;
152 }
153 template <typename TRAIT>
155  return this->tensor_RH_upperleg;
156 }
157 template <typename TRAIT>
159  return this->tensor_RH_lowerleg;
160 }
161 template <typename TRAIT>
163  return this->tensor_trunk.getMass();
164 }
165 template <typename TRAIT>
167  return this->tensor_LF_hipassembly.getMass();
168 }
169 template <typename TRAIT>
171  return this->tensor_LF_upperleg.getMass();
172 }
173 template <typename TRAIT>
175  return this->tensor_LF_lowerleg.getMass();
176 }
177 template <typename TRAIT>
179  return this->tensor_RF_hipassembly.getMass();
180 }
181 template <typename TRAIT>
183  return this->tensor_RF_upperleg.getMass();
184 }
185 template <typename TRAIT>
187  return this->tensor_RF_lowerleg.getMass();
188 }
189 template <typename TRAIT>
191  return this->tensor_LH_hipassembly.getMass();
192 }
193 template <typename TRAIT>
195  return this->tensor_LH_upperleg.getMass();
196 }
197 template <typename TRAIT>
199  return this->tensor_LH_lowerleg.getMass();
200 }
201 template <typename TRAIT>
203  return this->tensor_RH_hipassembly.getMass();
204 }
205 template <typename TRAIT>
207  return this->tensor_RH_upperleg.getMass();
208 }
209 template <typename TRAIT>
211  return this->tensor_RH_lowerleg.getMass();
212 }
213 template <typename TRAIT>
215  return this->com_trunk;
216 }
217 template <typename TRAIT>
219  return this->com_LF_hipassembly;
220 }
221 template <typename TRAIT>
223  return this->com_LF_upperleg;
224 }
225 template <typename TRAIT>
227  return this->com_LF_lowerleg;
228 }
229 template <typename TRAIT>
231  return this->com_RF_hipassembly;
232 }
233 template <typename TRAIT>
235  return this->com_RF_upperleg;
236 }
237 template <typename TRAIT>
239  return this->com_RF_lowerleg;
240 }
241 template <typename TRAIT>
243  return this->com_LH_hipassembly;
244 }
245 template <typename TRAIT>
247  return this->com_LH_upperleg;
248 }
249 template <typename TRAIT>
251  return this->com_LH_lowerleg;
252 }
253 template <typename TRAIT>
255  return this->com_RH_hipassembly;
256 }
257 template <typename TRAIT>
259  return this->com_RH_upperleg;
260 }
261 template <typename TRAIT>
263  return this->com_RH_lowerleg;
264 }
265 
266 template <typename TRAIT>
268  return 47.376 + 2.93 + 2.638 + 0.881 + 2.93 + 2.638 + 0.881 + 2.93 + 2.638 + 0.881 + 2.93 + 2.638 + 0.881;
269 }
270 
271 }
272 
274 
275 }
276 }
277 }
278 
279 #include "inertia_properties.impl.h"
280 
281 #endif
const IMatrix & getTensor_LH_lowerleg() const
Definition: inertia_properties.h:146
const IMatrix & getTensor_LF_hipassembly() const
Definition: inertia_properties.h:114
const Vec3d & getCOM_RH_hipassembly() const
Definition: inertia_properties.h:254
InertiaProperties()
Definition: inertia_properties.impl.h:2
const IMatrix & getTensor_LH_hipassembly() const
Definition: inertia_properties.h:138
const Vec3d & getCOM_LF_hipassembly() const
Definition: inertia_properties.h:218
const IMatrix & getTensor_RH_lowerleg() const
Definition: inertia_properties.h:158
Definition: InertiaMatrix.h:25
const IMatrix & getTensor_RH_hipassembly() const
Definition: inertia_properties.h:150
const Vec3d & getCOM_RF_hipassembly() const
Definition: inertia_properties.h:230
Scalar getMass_LH_hipassembly() const
Definition: inertia_properties.h:190
iit::rbd::tpl::InertiaMatrixDense< Scalar > IMatrix
Definition: inertia_properties.h:30
const Vec3d & getCOM_RF_lowerleg() const
Definition: inertia_properties.h:238
Scalar getTotalMass() const
Definition: inertia_properties.h:267
Scalar getMass_RH_hipassembly() const
Definition: inertia_properties.h:202
Scalar getMass_RH_lowerleg() const
Definition: inertia_properties.h:210
CoreS::Vector3 Vec3d
Definition: inertia_properties.h:31
Scalar getMass_LH_upperleg() const
Definition: inertia_properties.h:194
Scalar getMass_RH_upperleg() const
Definition: inertia_properties.h:206
Definition: inertia_properties.h:24
~InertiaProperties()
Definition: inertia_properties.h:107
Definition: rbd.h:72
Scalar getMass_RF_lowerleg() const
Definition: inertia_properties.h:186
const IMatrix & getTensor_RF_upperleg() const
Definition: inertia_properties.h:130
const IMatrix & getTensor_LF_lowerleg() const
Definition: inertia_properties.h:122
Scalar getMass_RF_upperleg() const
Definition: inertia_properties.h:182
const Vec3d & getCOM_RH_lowerleg() const
Definition: inertia_properties.h:262
const IMatrix & getTensor_LH_upperleg() const
Definition: inertia_properties.h:142
const Vec3d & getCOM_LH_hipassembly() const
Definition: inertia_properties.h:242
iit::rbd::Core< Scalar > CoreS
Definition: inertia_properties.h:29
const IMatrix & getTensor_trunk() const
Definition: inertia_properties.h:110
const Vec3d & getCOM_LF_lowerleg() const
Definition: inertia_properties.h:226
const IMatrix & getTensor_RH_upperleg() const
Definition: inertia_properties.h:154
const Vec3d & getCOM_RF_upperleg() const
Definition: inertia_properties.h:234
tpl::InertiaMatrixDense< double > InertiaMatrixDense
Definition: InertiaMatrix.h:316
const Vec3d & getCOM_RH_upperleg() const
Definition: inertia_properties.h:258
Scalar getMass_LF_hipassembly() const
Definition: inertia_properties.h:166
const IMatrix & getTensor_RF_hipassembly() const
Definition: inertia_properties.h:126
const Vec3d & getCOM_LH_upperleg() const
Definition: inertia_properties.h:246
Scalar getMass_LH_lowerleg() const
Definition: inertia_properties.h:198
const IMatrix & getTensor_LF_upperleg() const
Definition: inertia_properties.h:118
Scalar getMass_LF_lowerleg() const
Definition: inertia_properties.h:174
const Vec3d & getCOM_LH_lowerleg() const
Definition: inertia_properties.h:250
const IMatrix & getTensor_RF_lowerleg() const
Definition: inertia_properties.h:134
const Vec3d & getCOM_LF_upperleg() const
Definition: inertia_properties.h:222
Scalar getMass_LF_upperleg() const
Definition: inertia_properties.h:170
const Vec3d & getCOM_trunk() const
Definition: inertia_properties.h:214
PlainMatrix< Scalar, 3, 1 > Vector3
Definition: rbd.h:80
Scalar getMass_RF_hipassembly() const
Definition: inertia_properties.h:178
EIGEN_MAKE_ALIGNED_OPERATOR_NEW typedef TRAIT::Scalar Scalar
Definition: inertia_properties.h:28
Scalar getMass_trunk() const
Definition: inertia_properties.h:162