1 #ifndef IIT_TESTHYQ_INVERSE_DYNAMICS_H_ 2 #define IIT_TESTHYQ_INVERSE_DYNAMICS_H_ 12 #include "transforms.h" 40 template <
typename TRAIT>
43 EIGEN_MAKE_ALIGNED_OPERATOR_NEW
45 typedef typename TRAIT::Scalar
Scalar;
56 typedef iit::TestHyQ::tpl::MotionTransforms<TRAIT>
MTransforms;
87 JointState& jForces, Acceleration& trunk_a,
88 const Acceleration& g,
const Velocity& trunk_v,
89 const JointState& q,
const JointState& qd,
const JointState& qdd,
90 const ExtForces& fext = zeroExtForces);
92 JointState& jForces, Acceleration& trunk_a,
93 const Acceleration& g,
const Velocity& trunk_v,
94 const JointState& qd,
const JointState& qdd,
95 const ExtForces& fext = zeroExtForces);
118 Force& baseWrench, JointState& jForces,
119 const Acceleration& g,
const Velocity& trunk_v,
const Acceleration& baseAccel,
120 const JointState& q,
const JointState& qd,
const JointState& qdd,
const ExtForces& fext = zeroExtForces);
122 Force& baseWrench, JointState& jForces,
123 const Acceleration& g,
const Velocity& trunk_v,
const Acceleration& baseAccel,
124 const JointState& qd,
const JointState& qdd,
const ExtForces& fext = zeroExtForces);
130 Force& baseWrench, JointState& jForces,
131 const Acceleration& g,
const JointState& q);
133 Force& baseWrench, JointState& jForces,
134 const Acceleration& g);
148 Force& baseWrench, JointState& jForces,
149 const Velocity& trunk_v,
const JointState& q,
const JointState& qd);
151 Force& baseWrench, JointState& jForces,
152 const Velocity& trunk_v,
const JointState& qd);
217 IProperties* inertiaProps;
222 const InertiaMatrix& LF_hipassembly_I;
223 Velocity LF_hipassembly_v;
224 Acceleration LF_hipassembly_a;
225 Force LF_hipassembly_f;
227 const InertiaMatrix& LF_upperleg_I;
228 Velocity LF_upperleg_v;
229 Acceleration LF_upperleg_a;
232 const InertiaMatrix& LF_lowerleg_I;
233 Velocity LF_lowerleg_v;
234 Acceleration LF_lowerleg_a;
237 const InertiaMatrix& RF_hipassembly_I;
238 Velocity RF_hipassembly_v;
239 Acceleration RF_hipassembly_a;
240 Force RF_hipassembly_f;
242 const InertiaMatrix& RF_upperleg_I;
243 Velocity RF_upperleg_v;
244 Acceleration RF_upperleg_a;
247 const InertiaMatrix& RF_lowerleg_I;
248 Velocity RF_lowerleg_v;
249 Acceleration RF_lowerleg_a;
252 const InertiaMatrix& LH_hipassembly_I;
253 Velocity LH_hipassembly_v;
254 Acceleration LH_hipassembly_a;
255 Force LH_hipassembly_f;
257 const InertiaMatrix& LH_upperleg_I;
258 Velocity LH_upperleg_v;
259 Acceleration LH_upperleg_a;
262 const InertiaMatrix& LH_lowerleg_I;
263 Velocity LH_lowerleg_v;
264 Acceleration LH_lowerleg_a;
267 const InertiaMatrix& RH_hipassembly_I;
268 Velocity RH_hipassembly_v;
269 Acceleration RH_hipassembly_a;
270 Force RH_hipassembly_f;
272 const InertiaMatrix& RH_upperleg_I;
273 Velocity RH_upperleg_v;
274 Acceleration RH_upperleg_a;
277 const InertiaMatrix& RH_lowerleg_I;
278 Velocity RH_lowerleg_v;
279 Acceleration RH_lowerleg_a;
283 const InertiaMatrix& trunk_I;
284 InertiaMatrix trunk_Ic;
287 InertiaMatrix LF_hipassembly_Ic;
288 InertiaMatrix LF_upperleg_Ic;
289 const InertiaMatrix& LF_lowerleg_Ic;
290 InertiaMatrix RF_hipassembly_Ic;
291 InertiaMatrix RF_upperleg_Ic;
292 const InertiaMatrix& RF_lowerleg_Ic;
293 InertiaMatrix LH_hipassembly_Ic;
294 InertiaMatrix LH_upperleg_Ic;
295 const InertiaMatrix& LH_lowerleg_Ic;
296 InertiaMatrix RH_hipassembly_Ic;
297 InertiaMatrix RH_upperleg_Ic;
298 const InertiaMatrix& RH_lowerleg_Ic;
301 static const ExtForces zeroExtForces;
304 template <
typename TRAIT>
307 (xm->fr_LF_hipassembly_X_fr_trunk)(q);
308 (xm->fr_LF_upperleg_X_fr_LF_hipassembly)(q);
309 (xm->fr_LF_lowerleg_X_fr_LF_upperleg)(q);
310 (xm->fr_RF_hipassembly_X_fr_trunk)(q);
311 (xm->fr_RF_upperleg_X_fr_RF_hipassembly)(q);
312 (xm->fr_RF_lowerleg_X_fr_RF_upperleg)(q);
313 (xm->fr_LH_hipassembly_X_fr_trunk)(q);
314 (xm->fr_LH_upperleg_X_fr_LH_hipassembly)(q);
315 (xm->fr_LH_lowerleg_X_fr_LH_upperleg)(q);
316 (xm->fr_RH_hipassembly_X_fr_trunk)(q);
317 (xm->fr_RH_upperleg_X_fr_RH_hipassembly)(q);
318 (xm->fr_RH_lowerleg_X_fr_RH_upperleg)(q);
321 template <
typename TRAIT>
329 id(jForces, trunk_a, g, trunk_v,
333 template <
typename TRAIT>
342 template <
typename TRAIT>
351 template <
typename TRAIT>
359 baseAccel, qd, qdd, fext);
const Force & getForce_LF_hipassembly() const
Definition: inverse_dynamics.h:178
const Acceleration & getAcceleration_RH_upperleg() const
Definition: inverse_dynamics.h:207
const Force & getForce_LH_upperleg() const
Definition: inverse_dynamics.h:199
void C_terms_fully_actuated(Force &baseWrench, JointState &jForces, const Velocity &trunk_v, const JointState &q, const JointState &qd)
Definition: inverse_dynamics.h:343
void secondPass_fullyActuated(JointState &jForces)
Definition: inverse_dynamics.impl.h:595
CoreS::Matrix66 Matrix66s
Definition: inverse_dynamics.h:55
const Force & getForce_RH_hipassembly() const
Definition: inverse_dynamics.h:205
CoreS::VelocityVector Velocity
Definition: inverse_dynamics.h:51
const Acceleration & getAcceleration_LF_upperleg() const
Definition: inverse_dynamics.h:180
const Velocity & getVelocity_LF_lowerleg() const
Definition: inverse_dynamics.h:182
Definition: inverse_dynamics.h:41
const Acceleration & getAcceleration_LH_hipassembly() const
Definition: inverse_dynamics.h:195
PlainMatrix< Scalar, 6, 6 > Matrix66
Definition: rbd.h:79
const Acceleration & getAcceleration_RF_hipassembly() const
Definition: inverse_dynamics.h:186
const Force & getForce_LH_lowerleg() const
Definition: inverse_dynamics.h:202
void G_terms_fully_actuated(Force &baseWrench, JointState &jForces, const Acceleration &g, const JointState &q)
Definition: inverse_dynamics.h:334
const Velocity & getVelocity_RH_hipassembly() const
Definition: inverse_dynamics.h:203
const Acceleration & getAcceleration_LH_upperleg() const
Definition: inverse_dynamics.h:198
const Force & getForce_trunk() const
Definition: inverse_dynamics.h:175
const Force & getForce_RH_lowerleg() const
Definition: inverse_dynamics.h:211
const Acceleration & getAcceleration_LF_hipassembly() const
Definition: inverse_dynamics.h:177
const Force & getForce_RF_upperleg() const
Definition: inverse_dynamics.h:190
const Force & getForce_LF_upperleg() const
Definition: inverse_dynamics.h:181
const Force & getForce_LH_hipassembly() const
Definition: inverse_dynamics.h:196
LinkDataMap< Force > ExtForces
Definition: inverse_dynamics.h:50
iit::rbd::tpl::InertiaMatrixDense< Scalar > InertiaMatrix
Definition: inverse_dynamics.h:53
CoreS::VelocityVector Acceleration
Definition: inverse_dynamics.h:52
const Velocity & getVelocity_LF_upperleg() const
Definition: inverse_dynamics.h:179
const Velocity & getVelocity_LH_upperleg() const
Definition: inverse_dynamics.h:197
void setJointStatus(const JointState &q) const
Definition: inverse_dynamics.h:305
const Force & getForce_LF_lowerleg() const
Definition: inverse_dynamics.h:184
const Velocity & getVelocity_RF_upperleg() const
Definition: inverse_dynamics.h:188
const Force & getForce_RH_upperleg() const
Definition: inverse_dynamics.h:208
InertiaProperties< TRAIT > IProperties
Definition: inverse_dynamics.h:57
Definition: inertia_properties.h:24
Definition: link_data_map.h:12
const Velocity & getVelocity_LH_lowerleg() const
Definition: inverse_dynamics.h:200
EIGEN_MAKE_ALIGNED_OPERATOR_NEW typedef TRAIT::Scalar Scalar
Definition: inverse_dynamics.h:45
iit::TestHyQ::tpl::JointState< Scalar > JointState
Definition: inverse_dynamics.h:54
const Force & getForce_RF_hipassembly() const
Definition: inverse_dynamics.h:187
Column12d< SCALAR > JointState
Definition: declarations.h:19
const Velocity & getVelocity_RF_lowerleg() const
Definition: inverse_dynamics.h:191
Vector6D ForceVector
a 3D subvector of a 6D vector
Definition: rbd.h:92
void id_fully_actuated(Force &baseWrench, JointState &jForces, const Acceleration &g, const Velocity &trunk_v, const Acceleration &baseAccel, const JointState &q, const JointState &qd, const JointState &qdd, const ExtForces &fext=zeroExtForces)
Definition: inverse_dynamics.h:352
const Acceleration & getAcceleration_RH_lowerleg() const
Definition: inverse_dynamics.h:210
iit::rbd::Core< Scalar > CoreS
Definition: inverse_dynamics.h:47
const Velocity & getVelocity_RH_lowerleg() const
Definition: inverse_dynamics.h:209
void id(JointState &jForces, Acceleration &trunk_a, const Acceleration &g, const Velocity &trunk_v, const JointState &q, const JointState &qd, const JointState &qdd, const ExtForces &fext=zeroExtForces)
Definition: inverse_dynamics.h:322
CoreS::ForceVector Force
Definition: inverse_dynamics.h:49
InverseDynamics(IProperties &in, MTransforms &tr)
Definition: inverse_dynamics.impl.h:7
iit::TestHyQ::tpl::MotionTransforms< TRAIT > MTransforms
Definition: inverse_dynamics.h:56
const Velocity & getVelocity_RF_hipassembly() const
Definition: inverse_dynamics.h:185
const Acceleration & getAcceleration_RF_upperleg() const
Definition: inverse_dynamics.h:189
const Velocity & getVelocity_LF_hipassembly() const
Definition: inverse_dynamics.h:176
Vector6D VelocityVector
a 3D subvector of a 6D vector
Definition: rbd.h:91
const Acceleration & getAcceleration_RF_lowerleg() const
Definition: inverse_dynamics.h:192
const Velocity & getVelocity_LH_hipassembly() const
Definition: inverse_dynamics.h:194
const Velocity & getVelocity_RH_upperleg() const
Definition: inverse_dynamics.h:206
const Acceleration & getAcceleration_LF_lowerleg() const
Definition: inverse_dynamics.h:183
const Force & getForce_RF_lowerleg() const
Definition: inverse_dynamics.h:193
const Acceleration & getAcceleration_RH_hipassembly() const
Definition: inverse_dynamics.h:204
const Acceleration & getAcceleration_LH_lowerleg() const
Definition: inverse_dynamics.h:201