4 template<
typename TRAIT>
8 template<
typename TRAIT>
10 inertiaProps( & inertia ),
11 motionTransforms( & transforms )
23 template <
typename TRAIT>
34 body_AI = inertiaProps->getTensor_body();
35 body_p = - fext[
BODY];
36 link1_AI = inertiaProps->getTensor_link1();
37 link1_p = - fext[
LINK1];
38 link2_AI = inertiaProps->getTensor_link2();
39 link2_p = - fext[
LINK2];
48 link1_v = (motionTransforms-> fr_link1_X_fr_body) * body_v;
52 iit::rbd::motionCrossProductMx<SCALAR>(link1_v, vcross);
60 link2_v = (motionTransforms-> fr_link2_X_fr_link1) * link1_v;
64 iit::rbd::motionCrossProductMx<SCALAR>(link2_v, vcross);
79 link2_U = link2_AI.col(
rbd::AZ);
83 pa = link2_p + Ia_r * link2_c + link2_U * link2_u/link2_D;
86 link1_p += (motionTransforms-> fr_link2_X_fr_link1).transpose() * pa;
90 link1_U = link1_AI.col(
rbd::AZ);
94 pa = link1_p + Ia_r * link1_c + link1_U * link1_u/link1_D;
97 body_p += (motionTransforms-> fr_link1_X_fr_body).transpose() * pa;
100 body_a = - TRAIT::solve(body_AI, body_p);
103 link1_a = (motionTransforms-> fr_link1_X_fr_body) * body_a + link1_c;
104 qdd(
JA) = (link1_u - link1_U.dot(link1_a)) / link1_D;
107 link2_a = (motionTransforms-> fr_link2_X_fr_link1) * link1_a + link2_c;
108 qdd(
JB) = (link2_u - link2_U.dot(link2_a)) / link2_D;
Definition: forward_dynamics.h:34
void compute_Ia_revolute(const MatrixBase< D1 > &IA, const Vec6< typename D1::Scalar > &U, const typename D1::Scalar &D, const MatrixBase< D2 > &Ia_const)
CoreS::Matrix66 Matrix66S
Definition: forward_dynamics.h:49
Definition: declarations.h:27
Definition: declarations.h:32
CoreS::ForceVector Force
Definition: forward_dynamics.h:44
Force< DScalar > vxIv(const Velocity< DScalar > &v, const MatrixBase< Derived > &I)
Definition: declarations.h:31
Definition: inertia_properties.h:25
ForwardDynamics(iit::ct_quadrotor::dyn::tpl::InertiaProperties< TRAIT > &in, MotionTransforms &tr)
Definition: forward_dynamics.impl.h:9
Definition: link_data_map.h:12
CoreS::VelocityVector Acceleration
Definition: forward_dynamics.h:46
CoreS::VelocityVector Velocity
Definition: forward_dynamics.h:45
iit::ct_quadrotor::tpl::JointState< SCALAR > JointState
Definition: forward_dynamics.h:48
void fd(JointState &qdd, Acceleration &body_a, const Velocity &body_v, const Acceleration &g, const JointState &q, const JointState &qd, const JointState &tau, const ExtForces &fext=zeroExtForces)
Definition: forward_dynamics.h:133
Definition: declarations.h:33
void ctransform_Ia_revolute(const MatrixBase< D1 > &Ia_A, const MatrixBase< D2 > &XM, const MatrixBase< D3 > &Ia_B_const)
Definition: declarations.h:26