articulatedbodyinertia.hpp
Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022 #ifndef KDL_ARTICULATEDBODYINERTIA_HPP
00023 #define KDL_ARTICULATEDBODYINERTIA_HPP
00024
00025 #include "frames.hpp"
00026
00027 #include "rotationalinertia.hpp"
00028 #include "rigidbodyinertia.hpp"
00029
00030 #include <Eigen/Core>
00031
00032 namespace KDL {
00033
00040 class ArticulatedBodyInertia{
00041 public:
00042
00046 ArticulatedBodyInertia(){
00047 *this=ArticulatedBodyInertia::Zero();
00048 }
00049
00054 ArticulatedBodyInertia(const RigidBodyInertia& rbi);
00055
00060 ArticulatedBodyInertia(double m, const Vector& oc=Vector::Zero(), const RotationalInertia& Ic=RotationalInertia::Zero());
00061
00065 static inline ArticulatedBodyInertia Zero(){
00066 return ArticulatedBodyInertia(Eigen::Matrix3d::Zero(),Eigen::Matrix3d::Zero(),Eigen::Matrix3d::Zero());
00067 };
00068
00069
00070 ~ArticulatedBodyInertia(){};
00071
00075 friend ArticulatedBodyInertia operator*(double a,const ArticulatedBodyInertia& I);
00081 friend ArticulatedBodyInertia operator+(const ArticulatedBodyInertia& Ia,const ArticulatedBodyInertia& Ib);
00082 friend ArticulatedBodyInertia operator+(const ArticulatedBodyInertia& Ia,const RigidBodyInertia& Ib);
00083 friend ArticulatedBodyInertia operator-(const ArticulatedBodyInertia& Ia,const ArticulatedBodyInertia& Ib);
00084 friend ArticulatedBodyInertia operator-(const ArticulatedBodyInertia& Ia,const RigidBodyInertia& Ib);
00085
00090 friend Wrench operator*(const ArticulatedBodyInertia& I,const Twist& t);
00091
00095 friend ArticulatedBodyInertia operator*(const Frame& T,const ArticulatedBodyInertia& I);
00100 friend ArticulatedBodyInertia operator*(const Rotation& R,const ArticulatedBodyInertia& I);
00101
00106 ArticulatedBodyInertia RefPoint(const Vector& p);
00107
00108 ArticulatedBodyInertia(const Eigen::Matrix3d& M,const Eigen::Matrix3d& H,const Eigen::Matrix3d& I);
00109
00110 Eigen::Matrix3d M;
00111 Eigen::Matrix3d H;
00112 Eigen::Matrix3d I;
00113 };
00114 }
00115
00116
00117 #endif