cisst-saw
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Types | Public Member Functions | List of all members
robMass Class Reference

#include <robMass.h>

Public Types

enum  Errno { ESUCCESS, EFAILURE }
 

Public Member Functions

vctFixedSizeMatrix< double, 3, 3 > ParallelAxis (double m, const vctFixedSizeVector< double, 3 > &t, const vctFixedSizeMatrix< double, 3, 3 > &I) const
 Parallel Axis Theorem. More...
 
 robMass ()
 Default constructor. More...
 
 robMass (double m, const vctFixedSizeVector< double, 3 > &com, const vctFixedSizeMatrix< double, 3, 3 > &D, const vctFixedSizeMatrix< double, 3, 3 > &V)
 
double Mass () const
 Return the mass. More...
 
vctFixedSizeVector< double, 3 > CenterOfMass () const
 Return the center of mass. More...
 
vctFixedSizeMatrix< double, 3, 3 > MomentOfInertia () const
 Return the moment of inertia tensor in the body frame. More...
 
vctFixedSizeMatrix< double, 3, 3 > MomentOfInertiaAtCOM () const
 
robMass::Errno ReadMass (std::istream &is)
 Read the mass from a input stream. More...
 
robMass::Errno WriteMass (std::ostream &os) const
 Write the mass from a output stream. More...
 

Member Enumeration Documentation

Enumerator
ESUCCESS 
EFAILURE 

Constructor & Destructor Documentation

robMass::robMass ( )

Default constructor.

Set the mass, center of mass and inertia to zero

robMass::robMass ( double  m,
const vctFixedSizeVector< double, 3 > &  com,
const vctFixedSizeMatrix< double, 3, 3 > &  D,
const vctFixedSizeMatrix< double, 3, 3 > &  V 
)

Member Function Documentation

vctFixedSizeVector<double,3> robMass::CenterOfMass ( ) const

Return the center of mass.

Return the center of mass. The center of mass is expressed in the coordinate frame of the body.

Returns
A 3D vector representing the center of mass
double robMass::Mass ( ) const

Return the mass.

Returns
The mass of the body
vctFixedSizeMatrix<double,3,3> robMass::MomentOfInertia ( ) const

Return the moment of inertia tensor in the body frame.

Return the moment of inertia tensor. The tensor is with respect to the coordinate frame of the body which does not necessarily coincide with the center of mass of the body and the principal axes.

Returns
A 3x3 moment of inertia tensor
vctFixedSizeMatrix<double,3,3> robMass::MomentOfInertiaAtCOM ( ) const
vctFixedSizeMatrix<double,3,3> robMass::ParallelAxis ( double  m,
const vctFixedSizeVector< double, 3 > &  t,
const vctFixedSizeMatrix< double, 3, 3 > &  I 
) const

Parallel Axis Theorem.

Finds the moment of inertia with respect to a parallel axis

robMass::Errno robMass::ReadMass ( std::istream &  is)

Read the mass from a input stream.

robMass::Errno robMass::WriteMass ( std::ostream &  os) const

Write the mass from a output stream.


The documentation for this class was generated from the following file: