Drake
DrakeJoint Class Referenceabstract

A joint defines a spatial relationship between two rigid bodies. More...

#include <drake/multibody/joints/drake_joint.h>

Collaboration diagram for DrakeJoint:
[legend]

Public Types

typedef Eigen::AutoDiffScalar< Eigen::Matrix< double, Eigen::Dynamic, 1, 0, 73, 1 > > AutoDiffFixedMaxSize
 Defines the maximum automatic differentiation data type size a joint can have. More...
 

Public Member Functions

 DrakeJoint (const std::string &name, const Eigen::Isometry3d &transform_to_parent_body, int num_positions, int num_velocities)
 A constructor for use by concrete joints to define the joint's name, fixed frame, and number of degrees of freedom. More...
 
virtual ~DrakeJoint ()
 The destructor. More...
 
std::unique_ptr< DrakeJointClone () const
 Returns a clone of this DrakeJoint. More...
 
const Eigen::Isometry3d & get_transform_to_parent_body () const
 Returns the transform X_PF giving the pose of the joint's "fixed" frame F in its parent body frame P. More...
 
int get_num_positions () const
 Returns the number of position states of this joint. More...
 
int get_num_velocities () const
 Returns the number of velocity states of this joint. More...
 
const std::string & get_name () const
 Returns the name of this joint. More...
 
virtual std::string get_position_name (int index) const =0
 Returns the name of a particular position degree of freedom of this joint. More...
 
virtual std::string get_velocity_name (int index) const
 Returns the name of a particular velocity degree of freedom of this joint. More...
 
const Eigen::Isometry3d & getTransformToParentBody () const
 
int getNumPositions () const
 
int getNumVelocities () const
 
const std::string & getName () const
 
virtual std::string getPositionName (int index) const =0
 
virtual std::string getVelocityName (int index) const
 
virtual bool is_floating () const
 
virtual bool isFloating () const
 
bool is_fixed () const
 Returns true if this joint is a FixedJoint. More...
 
virtual Eigen::VectorXd zeroConfiguration () const =0
 
virtual Eigen::VectorXd randomConfiguration (std::default_random_engine &generator) const =0
 
virtual const Eigen::VectorXd & getJointLimitMin () const
 
virtual const Eigen::VectorXd & getJointLimitMax () const
 
virtual const Eigen::VectorXd & get_joint_limit_stiffness () const
 
virtual const Eigen::VectorXd & get_joint_limit_dissipation () const
 

Public Attributes

POSITION_AND_VELOCITY_DEPENDENT_METHODS(Eigen::AutoDiffScalar< Eigen::VectorXd >) EIGEN_MAKE_ALIGNED_OPERATOR_NEW protected Eigen::VectorXd joint_limit_min
 
Eigen::VectorXd joint_limit_max
 
Eigen::VectorXd joint_limit_stiffness_
 
Eigen::VectorXd joint_limit_dissipation_
 

Static Public Attributes

static const int MAX_NUM_POSITIONS = 7
 Defines the maximum number of position states a joint can have. More...
 
static const int MAX_NUM_VELOCITIES = 6
 Defines the maximum number of velocity states a joint can have. More...
 

Protected Member Functions

virtual std::unique_ptr< DrakeJointDoClone () const =0
 Allows descendent classes to perform the actual clone operation. More...
 
void InitializeClone (DrakeJoint *clone) const
 Initializes the private member variables within the provided clone. More...
 
virtual void DoInitializeClone (DrakeJoint *clone) const =0
 Initializes any additional members within clone that could not be set during construction. More...
 

Detailed Description

A joint defines a spatial relationship between two rigid bodies.

Member Typedef Documentation

typedef Eigen::AutoDiffScalar< Eigen::Matrix<double, Eigen::Dynamic, 1, 0, 73, 1> > AutoDiffFixedMaxSize

Defines the maximum automatic differentiation data type size a joint can have.

Constructor & Destructor Documentation

DrakeJoint ( const std::string &  name,
const Eigen::Isometry3d &  transform_to_parent_body,
int  num_positions,
int  num_velocities 
)

A constructor for use by concrete joints to define the joint's name, fixed frame, and number of degrees of freedom.

Parameters
[in]nameThe joint's name. This can be anything; it does not have to be unique.
[in]transform_to_parent_bodyDefines the configuration of the joint's fixed frame relative to the joint's parent body's frame.
[in]num_positionsThe number of position states of the joint.
[in]num_velocitiesThe number of velocity states of the joint.
~DrakeJoint ( )
virtual

The destructor.

Member Function Documentation

std::unique_ptr< DrakeJoint > Clone ( ) const

Returns a clone of this DrakeJoint.

Here is the call graph for this function:

Here is the caller graph for this function:

virtual std::unique_ptr<DrakeJoint> DoClone ( ) const
protectedpure virtual

Allows descendent classes to perform the actual clone operation.

Here is the caller graph for this function:

virtual void DoInitializeClone ( DrakeJoint clone) const
protectedpure virtual

Initializes any additional members within clone that could not be set during construction.

Here is the caller graph for this function:

const Eigen::VectorXd & get_joint_limit_dissipation ( ) const
virtual

Here is the caller graph for this function:

const Eigen::VectorXd & get_joint_limit_stiffness ( ) const
virtual

Here is the caller graph for this function:

const std::string & get_name ( ) const

Returns the name of this joint.

Here is the caller graph for this function:

int get_num_positions ( ) const

Returns the number of position states of this joint.

Here is the caller graph for this function:

int get_num_velocities ( ) const

Returns the number of velocity states of this joint.

Here is the caller graph for this function:

virtual std::string get_position_name ( int  index) const
pure virtual

Returns the name of a particular position degree of freedom of this joint.

Parameters
[in]indexThe index of the position degree of freedom. This value must be between 0 and get_num_positions() - 1.

Here is the caller graph for this function:

const Isometry3d & get_transform_to_parent_body ( ) const

Returns the transform X_PF giving the pose of the joint's "fixed" frame F in its parent body frame P.

Frame F is the joint frame that is fixed to the parent body; thus X_PF is not configuration dependent.

To clarify the sense of the returned transform X_PF, consider the location of a point Q somewhere in space. Let p_PQ be point Q measured and expressed in frame P and p_FQ be point Q measured and expressed in frame F. Then p_PQ is given by:

p_PQ = X_PF * p_FQ

Here is the caller graph for this function:

std::string get_velocity_name ( int  index) const
virtual

Returns the name of a particular velocity degree of freedom of this joint.

Parameters
[in]indexThe index of the velocity degree of freedom. This value must be between 0 and get_num_velocities() - 1.

Here is the call graph for this function:

Here is the caller graph for this function:

const Eigen::VectorXd & getJointLimitMax ( ) const
virtual

Here is the caller graph for this function:

const Eigen::VectorXd & getJointLimitMin ( ) const
virtual

Here is the caller graph for this function:

const std::string & getName ( ) const

Here is the call graph for this function:

int getNumPositions ( ) const

Here is the call graph for this function:

int getNumVelocities ( ) const

Here is the call graph for this function:

virtual std::string getPositionName ( int  index) const
pure virtual
const Eigen::Isometry3d & getTransformToParentBody ( ) const

Here is the call graph for this function:

std::string getVelocityName ( int  index) const
virtual

Here is the call graph for this function:

void InitializeClone ( DrakeJoint clone) const
protected

Initializes the private member variables within the provided clone.

Here is the call graph for this function:

Here is the caller graph for this function:

bool is_fixed ( ) const
inline

Returns true if this joint is a FixedJoint.

Here is the call graph for this function:

Here is the caller graph for this function:

virtual bool is_floating ( ) const
inlinevirtual

Here is the caller graph for this function:

virtual bool isFloating ( ) const
inlinevirtual

Here is the call graph for this function:

virtual Eigen::VectorXd randomConfiguration ( std::default_random_engine &  generator) const
pure virtual

Here is the caller graph for this function:

virtual Eigen::VectorXd zeroConfiguration ( ) const
pure virtual

Here is the caller graph for this function:

Member Data Documentation

Eigen::VectorXd joint_limit_dissipation_
Eigen::VectorXd joint_limit_max
POSITION_AND_VELOCITY_DEPENDENT_METHODS ( Eigen::AutoDiffScalar<Eigen::VectorXd>) EIGEN_MAKE_ALIGNED_OPERATOR_NEW protected Eigen::VectorXd joint_limit_min
Eigen::VectorXd joint_limit_stiffness_
const int MAX_NUM_POSITIONS = 7
static

Defines the maximum number of position states a joint can have.

const int MAX_NUM_VELOCITIES = 6
static

Defines the maximum number of velocity states a joint can have.


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