Main Page   Modules   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages  

OSCAR::RRStatics Class Reference
[Dynamics]

An abstract class for calculating static forces. More...

#include <Statics.h>

Inheritance diagram for OSCAR::RRStatics:

Inheritance graph
[legend]
List of all members.

Public Methods

 RRStatics (unsigned int dof, const String &linkCGandMassFile, const Vector3D &gravity=Vector3D(0.0, 0.0,-9.8))
 RRStatics (unsigned int dof, const MatrixData &linkCGandMass, const Vector3D &gravity=Vector3D(0.0, 0.0,-9.8))
virtual ~RRStatics ()
virtual bool GetGravityTorques (Vector &torques)=0
bool SetEEFJacobianTranspose (const Matrix *jacobianTranspose)
virtual bool GetLoadTorques (const HandPose &eefLoad, Vector &torques)

Protected Attributes

unsigned int DOF
MatrixData linkCGmassData
Vector gravity
VectorgravityTorques
const Matrixjt

Detailed Description

Author:
Chalongrath Pholsiri
Provides interface for calculating gravity torques and EEF load torques.


Constructor & Destructor Documentation

OSCAR::RRStatics::RRStatics unsigned int    dof,
const String   linkCGandMassFile,
const Vector3D   gravity = Vector3D(0.0, 0.0,-9.8)
 

Constructor.

Parameters:
dof Degrees of freedom (number of joints) of the robot.
linkCGandMassFile Name of file containing link center of gravity and mass data. The format of the data is as follows. The number of rows is equal to DOF. The number of columns is 4, with the first three indicating the center of gravity of the link and the last one being the mass of that link. The following example is for a 2-D planar robot.

# This file contains centers of gravity and masses for a 2-DOF planar robot.
# X Y Z mass
0.2 0.0 0.0 5 # link 1
0.1 0.0 0.0 3 # link 2

Parameters:
gravity Vector3D object of the gravity constant. Default is Vector3D(0,0,9.8), which is the gravity constant in SI unit in the Z-direction.
Exceptions:
dofAndMassDataMismatch dofAndMassDataMismatch

OSCAR::RRStatics::RRStatics unsigned int    dof,
const MatrixData   linkCGandMass,
const Vector3D   gravity = Vector3D(0.0, 0.0,-9.8)
 

Constructor.

Parameters:
dof Degrees of freedom (number of joints) of the robot.
linkCGandMass MatrixData object containing link center of gravity and mass data. The number of rows is equal to DOF, each corresponding to each link. The number of columns is 4, with the first three indicating the center of gravity of the link and the last one being the mass of that link.
gravity Vector3D object of the gravity constant. Default is Vector3D(0,0,9.8), which is the gravity constant in SI unit in the Z-direction.
Exceptions:
dofAndMassDataMismatch dofAndMassDataMismatch

virtual OSCAR::RRStatics::~RRStatics   [virtual]
 


Member Function Documentation

virtual bool OSCAR::RRStatics::GetGravityTorques Vector   torques [pure virtual]
 

A pure virtual function for calculating the gravity torques.

Returns:
true if torques is of size DOF. If not, then false. Call GetError for more detailed error information.
Parameters:
torques Vector object of size DOF returning the gravity torques.
Exceptions:
vectorSizeMismatch vectorSizeMismatch

Implemented in OSCAR::IDLagrange, OSCAR::IDNewtonEuler, and OSCAR::InverseDynamics.

virtual bool OSCAR::RRStatics::GetLoadTorques const HandPose   eefLoad,
Vector   torques
[virtual]
 

Calculates the joint torques from the EEF load.

Must call SetEEFJacobianTranspose(const Matrix* jacobianTranspose) to set the Jacobian transpose before calling this function.

Returns:
false if any of these happens:
Parameters:
eefLoad The EEF load.
torques Vector object of size DOF returning the joint torques.
Exceptions:
vectorSizeMismatch vectorSizeMismatch
See also:
SetEEFJacobianTranspose(const Matrix* jacobianTranspose)

bool OSCAR::RRStatics::SetEEFJacobianTranspose const Matrix   jacobianTranspose
 

Set the EEF Jacobian transpose. This is used to calculate joint torques due to EEF load. jacobianTranspose must be an nX6 matrix (The transpose of FULL Jacobian).

Returns:
true if jacobianTranspose is of the right size. If not, then false. Call GetError for more detailed error information.
Parameters:
jacobianTranspose Pointer to a constant Matrix object containing the Jacobian transpose.
Exceptions:
matrixSizeMismatch matrixSizeMismatch
See also:
GetLoadTorques(const HandPose& eefLoad, Vector& torques)


Member Data Documentation

unsigned int OSCAR::RRStatics::DOF [protected]
 

Vector OSCAR::RRStatics::gravity [protected]
 

Vector* OSCAR::RRStatics::gravityTorques [protected]
 

const Matrix* OSCAR::RRStatics::jt [protected]
 

MatrixData OSCAR::RRStatics::linkCGmassData [protected]
 


The documentation for this class was generated from the following file:
RRG Homepage OSCAR Overview OSCAR Tutorials Simulations