30 this->
M=Eigen::Matrix3d::Identity()*rbi.
m;
31 this->
I=Eigen::Map<const Eigen::Matrix3d>(rbi.
I.
data);
32 this->
H << 0,-rbi.
h[2],rbi.
h[1],
70 Eigen::Vector3d::Map(result.
force.
data)=I.
M*Eigen::Vector3d::Map(t.
vel.
data)+I.
H.transpose()*Eigen::Vector3d::Map(t.
rot.
data);
80 Eigen::Map<Eigen::Matrix3d> E(X.
M.
data);
81 Eigen::Matrix3d rcross;
82 rcross << 0,-X.
p[2],X.
p[1],
86 Eigen::Matrix3d HrM=I.
H-rcross*I.
M;
87 return ArticulatedBodyInertia(E*I.
M*E.transpose(),E*HrM*E.transpose(),E*(I.
I-rcross*I.
H.transpose()+HrM*rcross)*E.transpose());
91 Eigen::Map<const Eigen::Matrix3d> E(M.
data);
99 Eigen::Matrix3d rcross;
100 rcross << 0,-p[2],p[1],
104 Eigen::Matrix3d HrM=this->
H-rcross*this->
M;
represents rotations in 3 dimensional space.
Vector vel
The velocity of that point.
6D Inertia of a rigid body
Vector torque
Torque that is applied at the origin of the current ref frame.
Rotation M
Orientation of the Frame.
represents both translational and rotational velocities.
6D Inertia of a articulated body
A concrete implementation of a 3 dimensional vector class.
friend ArticulatedBodyInertia operator-(const ArticulatedBodyInertia &Ia, const ArticulatedBodyInertia &Ib)
Vector rot
The rotational velocity of that point.
Frame Inverse() const
Gives back inverse transformation of a Frame.
Vector p
origine of the Frame
ArticulatedBodyInertia RefPoint(const Vector &p)
friend ArticulatedBodyInertia operator+(const ArticulatedBodyInertia &Ia, const ArticulatedBodyInertia &Ib)
friend ArticulatedBodyInertia operator*(double a, const ArticulatedBodyInertia &I)
Vector force
Force that is applied at the origin of the current ref frame.
represents a frame transformation in 3D space (rotation + translation)
represents both translational and rotational acceleration.