MULTIBODY SIMULATION SOFTWARE - API documentation

chrono::ChMarker Class Reference

#include <CHmarker.h>

Inheritance diagram for chrono::ChMarker:

Inheritance graph
[legend]
Collaboration diagram for chrono::ChMarker:

Collaboration graph
[legend]

List of all members.

Public Types

enum  eChMarkerMotion { M_MOTION_FUNCTIONS = 0, M_MOTION_KEYFRAMED = 1, M_MOTION_EXTERNAL = 2 }

Public Member Functions

 ChMarker (char myname[], ChBody *myBody, Coordsys myrel_pos, Coordsys myrel_pos_dt, Coordsys myrel_pos_dtdt)
void Copy (ChMarker *source)
ChBodyGetBody ()
void SetBody (ChBody *newRB)
void Impose_Rel_Coord (Coordsys m_coord)
void Impose_Abs_Coord (Coordsys m_coord)
Coordsys GetRest_Coord ()
ChFrameMoving< double > & GetAbsFrame ()
Coordsys GetAbsCoord ()
Coordsys GetAbsCoord_dt ()
Coordsys GetAbsCoord_dtdt ()
void SetAbsCoord (Coordsys newpos)
void SetAbsCoord_dt (Coordsys newpos_dt)
void SetAbsCoord_dtdt (Coordsys newpos_dtdt)
Vector GetAbsWvel ()
Vector GetAbsWacc ()
void SetMotion_X (ChFunction *m_funct)
void SetMotion_Y (ChFunction *m_funct)
void SetMotion_Z (ChFunction *m_funct)
void SetMotion_ang (ChFunction *m_funct)
void SetMotion_axis (Vector m_axis)
ChFunctionGetMotion_X ()
ChFunctionGetMotion_Y ()
ChFunctionGetMotion_Z ()
ChFunctionGetMotion_ang ()
Vector GetMotion_axis ()
void SetMotionType (eChMarkerMotion m_motion)
eChMarkerMotion GetMotionType ()
void UpdateTime (double mytime)
void UpdateState ()
void Update (double mytime)
void UpdateExternalGeometry ()
void UpdatedExternalTime (double prevtime, double mtime)
Vector Point_World2Ref (Vector *mpoint)
Vector Point_Ref2World (Vector *mpoint)
Vector Dir_World2Ref (Vector *mpoint)
Vector Dir_Ref2World (Vector *mpoint)
void StreamOUT (ChStreamOutAscii &mstream)
void StreamIN (ChStreamInBinary &mstream)
void StreamOUT (ChStreamOutBinary &mstream)


Detailed Description

Class for 'markers'.

Markers are auxiliary reference frames which belong to rigid bodies ChBody() , and move together with them. Most often, markers are used as references to build ChLink() constraints between two rigid bodies. The ChMarker objects allow also to user-define a motion law of marker respect to parent ChBody, if needed to represent imposed trajectories etc.


Member Enumeration Documentation

enum chrono::ChMarker::eChMarkerMotion

Enumerator:
M_MOTION_FUNCTIONS  Uses it's own x,y,z,angle ch functions (default).
M_MOTION_KEYFRAMED  The marker is moved via external functions, for examples Real3d keyframing, so backward dirrerentiation will be used to guess derivatives.
M_MOTION_EXTERNAL  Someone (i.e. a constraint object) is moving the marker and will also provide the correct derivatives.


Member Function Documentation

ChBody* chrono::ChMarker::GetBody (  ) 

Gets the address of the parent rigid body.

void chrono::ChMarker::SetBody ( ChBody newRB  ) 

Sets the parent rigid body.

void chrono::ChMarker::Impose_Rel_Coord ( Coordsys  m_coord  ) 

Set body-relative coord. and update auxiliary variables Also, current position becomes the 'resting position' coordinates for the current time.

void chrono::ChMarker::Impose_Abs_Coord ( Coordsys  m_coord  ) 

Set absolute coordinates and update auxiliary variables Also, current position becomes the 'resting position' coordinates for the current time.

Coordsys chrono::ChMarker::GetRest_Coord (  ) 

Get the 'resting position' (that is, the position which the marker should have when the x,y,z motion laws are at time=0).

ChFrameMoving<double>& chrono::ChMarker::GetAbsFrame (  ) 

Get reference to the inner 'absolute frame' auxiliary coordinates. This object (coordinates/speeds/accel. of marker expressed in absolute coordinates) is useful for performace reasons. Note! it is updated only after each Update() function.

Coordsys chrono::ChMarker::GetAbsCoord (  ) 

Get the translation and rotation (as a ChCoordsys) of the marker respect to the absolute coordinates.

Coordsys chrono::ChMarker::GetAbsCoord_dt (  ) 

Get the speed of translation and rotation (as a derived ChCoordsys) of the marker respect to the absolute coordinates.

Coordsys chrono::ChMarker::GetAbsCoord_dtdt (  ) 

Get the acceleration of translation and rotation (as a derived ChCoordsys) of the marker respect to the absolute coordinates.

void chrono::ChMarker::SetAbsCoord ( Coordsys  newpos  ) 

Set the translation and rotation (as a ChCoordsys) of the marker respect to the absolute coordinates. NOTE! inner use only, for the moment. Use Impose_Abs_Coord() if needed.

void chrono::ChMarker::SetAbsCoord_dt ( Coordsys  newpos_dt  ) 

Set the speed of translation and rotation (as a ChCoordsys) of the marker respect to the absolute coordinates. NOTE! inner use only, for the moment.

void chrono::ChMarker::SetAbsCoord_dtdt ( Coordsys  newpos_dtdt  ) 

Set the speed of translation and rotation (as a ChCoordsys) of the marker respect to the absolute coordinates. NOTE! inner use only, for the moment.

Vector chrono::ChMarker::GetAbsWvel (  ) 

Get the angular speed respect to absolute coordinates, expressed in absolute coordinates.

Vector chrono::ChMarker::GetAbsWacc (  ) 

Get the angular acceleration respect to absolute coordinates, expressed in absolute coordinates.

void chrono::ChMarker::SetMotion_X ( ChFunction m_funct  ) 

Set the imposed motion law, for translation on X body axis.

void chrono::ChMarker::SetMotion_Y ( ChFunction m_funct  ) 

Set the imposed motion law, for translation on Y body axis.

void chrono::ChMarker::SetMotion_Z ( ChFunction m_funct  ) 

Set the imposed motion law, for translation on Z body axis.

void chrono::ChMarker::SetMotion_ang ( ChFunction m_funct  ) 

Set the imposed motion law, for rotation about an axis.

void chrono::ChMarker::SetMotion_axis ( Vector  m_axis  ) 

Set the axis of rotation, if rotation motion law is used.

ChFunction* chrono::ChMarker::GetMotion_X (  ) 

The imposed motion law, for translation on X body axis.

ChFunction* chrono::ChMarker::GetMotion_Y (  ) 

The imposed motion law, for translation on Y body axis.

ChFunction* chrono::ChMarker::GetMotion_Z (  ) 

The imposed motion law, for translation on Z body axis.

ChFunction* chrono::ChMarker::GetMotion_ang (  ) 

The imposed motion law, for rotation about an axis.

Vector chrono::ChMarker::GetMotion_axis (  ) 

Get the axis of rotation, if rotation motion law is used.

void chrono::ChMarker::SetMotionType ( eChMarkerMotion  m_motion  ) 

Sets the way the motion of this marker (if any) is handled (see the eChMarkerMotion enum options).

eChMarkerMotion chrono::ChMarker::GetMotionType (  ) 

Gets the way the motion of this marker (if any) is handled (see the eChMarkerMotion enum options).

void chrono::ChMarker::UpdateTime ( double  mytime  ) 

Updates the time.dependant variables (ex: ChFunction objects which impose the body-relative motion, etc.)

void chrono::ChMarker::UpdateState (  ) 

Given current state, updates auxiliary variables (for example the abs_frame data, containing the absolute pos/speed/acc of the marker.

void chrono::ChMarker::Update ( double  mytime  ) 

Both UpdateTime() and UpdateState() at once.

void chrono::ChMarker::UpdateExternalGeometry (  ) 

Tells to the associated external object ChExternalObject() ,if any, that its 3D shape must be updated in order to syncronize to marker coordinates

void chrono::ChMarker::UpdatedExternalTime ( double  prevtime,
double  mtime 
)

Someone (ex. an ChExternalObject() ) may send this message to the marker to tell that time has changed (even if simulation is not running! - so it is different from the usual UpdateTime() -)

Vector chrono::ChMarker::Point_World2Ref ( Vector mpoint  ) 

Utilities for coordinate transformations

void chrono::ChMarker::StreamOUT ( ChStreamOutAscii mstream  )  [virtual]

Method to allow serialization of transient data in ascii, as a readable item, for example "chrono::GetLog() << myobject;"

Reimplemented from chrono::ChObj.

void chrono::ChMarker::StreamIN ( ChStreamInBinary mstream  )  [virtual]

Method to allow deserializing a persistent binary archive (ex: a file) into transient data.

Reimplemented from chrono::ChObj.

void chrono::ChMarker::StreamOUT ( ChStreamOutBinary mstream  )  [virtual]

Method to allow serializing transient data into a persistent binary archive (ex: a file).

Reimplemented from chrono::ChObj.


CHRONO::ENGINE
C++ library for multibody simulation, (C) Alessandro Tasora
This API documentation has been generated on 17 Jul 2009 by Doxygen