Drake
BodyFrame< T > Class Template Referencefinal

A BodyFrame is a material Frame that serves as the unique reference frame for a Body. More...

#include <multibody/multibody_tree/body.h>

Inheritance diagram for BodyFrame< T >:
[legend]
Collaboration diagram for BodyFrame< T >:
[legend]

Public Member Functions

Isometry3< T > CalcPoseInBodyFrame (const systems::Context< T > &) const override
 Returns the pose X_BF of this frame F in the body frame B associated with this frame. More...
 
Isometry3< T > CalcOffsetPoseInBody (const systems::Context< T > &, const Isometry3< T > &X_FQ) const override
 Given the offset pose X_FQ of a frame Q in this frame F, this method computes the pose X_BQ of frame Q in the body frame B to which this frame is attached. More...
 
Does not allow copy, move, or assignment
 BodyFrame (const BodyFrame &)=delete
 
BodyFrameoperator= (const BodyFrame &)=delete
 
 BodyFrame (BodyFrame &&)=delete
 
BodyFrameoperator= (BodyFrame &&)=delete
 
- Public Member Functions inherited from Frame< T >
const Body< T > & get_body () const
 Returns a const reference to the body associated to this Frame. More...
 
template<typename ToScalar >
std::unique_ptr< Frame< ToScalar > > CloneToScalar (const MultibodyTree< ToScalar > &tree_clone) const
 NVI to DoCloneToScalar() templated on the scalar type of the new clone to be created. More...
 
 Frame (const Frame &)=delete
 
Frameoperator= (const Frame &)=delete
 
 Frame (Frame &&)=delete
 
Frameoperator= (Frame &&)=delete
 

Protected Member Functions

std::unique_ptr< Frame< double > > DoCloneToScalar (const MultibodyTree< double > &tree_clone) const override
 Clones this Frame (templated on T) to a frame templated on double. More...
 
std::unique_ptr< Frame< AutoDiffXd > > DoCloneToScalar (const MultibodyTree< AutoDiffXd > &tree_clone) const override
 Clones this Frame (templated on T) to a frame templated on AutoDiffXd. More...
 
- Protected Member Functions inherited from Frame< T >
 Frame (const Body< T > &body)
 Only derived classes can use this constructor. More...
 

Friends

class Body< T >
 
template<typename >
class BodyFrame
 

Detailed Description

template<typename T>
class drake::multibody::BodyFrame< T >

A BodyFrame is a material Frame that serves as the unique reference frame for a Body.

Each Body B, regardless of whether it represents a rigid body or a flexible body, has a unique body frame for which we use the same symbol B (with meaning clear from context). The body frame is also referred to as a reference frame in the literature for flexible body mechanics modeling using the Finite Element Method. All properties of a body are defined with respect to its body frame, including its mass properties and attachment locations for joints, constraints, actuators, geometry and so on. Run time motion of the body is defined with respect to the motion of its body frame. We represent a body frame by a BodyFrame object that is created whenever a Body is constructed and is owned by the Body.

Note that the BodyFrame associated with a body does not necessarily need to be located at its center of mass nor does it need to be aligned with the body's principal axes, although, in practice, it frequently is. For flexible bodies, BodyFrame provides a representation for the body's reference frame. The flexible degrees of freedom associated with a flexible body describe the body's deformation in this frame. Therefore, the motion of a flexible body is defined by the motion of its BodyFrame, or reference frame, plus the motion of the material points on the body with respect to its BodyFrame.

A BodyFrame and Body are tightly coupled concepts; neither makes sense without the other. Therefore, a BodyFrame instance is constructed in conjunction with its Body and cannot be constructed anywhere else. However, you can still access the frame associated with a body, see Body::get_body_frame(). This access is more than a convenience; you can use the BodyFrame to define other frames on the body and to attach other multibody elements to it.

Template Parameters
TThe scalar type. Must be a valid Eigen scalar.

Constructor & Destructor Documentation

BodyFrame ( const BodyFrame< T > &  )
delete
BodyFrame ( BodyFrame< T > &&  )
delete

Member Function Documentation

Isometry3<T> CalcOffsetPoseInBody ( const systems::Context< T > &  context,
const Isometry3< T > &  X_FQ 
) const
inlineoverridevirtual

Given the offset pose X_FQ of a frame Q in this frame F, this method computes the pose X_BQ of frame Q in the body frame B to which this frame is attached.

In other words, if the pose of this frame F in the body frame B is X_BF, this method computes the pose X_BQ of frame Q in the body frame B as X_BQ = X_BF * X_FQ. In particular, if this isthe body frame B, i.e.X_BFis the identity transformation, this method directly returnsX_FQ`. Specific frame subclasses can override this method to provide faster implementations if needed.

Reimplemented from Frame< T >.

Isometry3<T> CalcPoseInBodyFrame ( const systems::Context< T > &  context) const
inlineoverridevirtual

Returns the pose X_BF of this frame F in the body frame B associated with this frame.

In particular, if this is the body frame B, this method directly returns the identity transformation.

Implements Frame< T >.

std::unique_ptr< Frame< double > > DoCloneToScalar ( const MultibodyTree< double > &  tree_clone) const
overrideprotectedvirtual

Clones this Frame (templated on T) to a frame templated on double.

Implements Frame< T >.

Here is the caller graph for this function:

std::unique_ptr< Frame< AutoDiffXd > > DoCloneToScalar ( const MultibodyTree< AutoDiffXd > &  tree_clone) const
overrideprotectedvirtual

Clones this Frame (templated on T) to a frame templated on AutoDiffXd.

Implements Frame< T >.

BodyFrame& operator= ( BodyFrame< T > &&  )
delete
BodyFrame& operator= ( const BodyFrame< T > &  )
delete

Friends And Related Function Documentation

friend class Body< T >
friend
friend class BodyFrame
friend

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