Template Function pinocchio::computeSubtreeMasses

Function Documentation

template<typename Scalar, int Options, template<typename, int> class JointCollectionTpl>
inline void pinocchio::computeSubtreeMasses(const ModelTpl<Scalar, Options, JointCollectionTpl> &model, DataTpl<Scalar, Options, JointCollectionTpl> &data)

Compute the mass of each kinematic subtree and store it in data.mass. The element mass[0] corresponds to the total mass of the model.

Note

If you are only interested in knowing the total mass of the model, computeTotalMass will probably be slightly faster.

Parameters:
  • model[in] The model structure of the rigid body system.

  • data[in] The data structure of the rigid body system.