145 if (!
merged(mergedBodyID))
148 <<
"Body " << mergedBodyID <<
" has not been merged" intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
DynamicList< spatialTransform > X0_
Transform for external forces to the bodies reference frame.
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
const subBody & mergedBody(label mergedBodyID) const
Return the merged body for the given body ID.
label bodyID(const word &name) const
Return the ID of the body with the given name.
dimensionedSphericalTensor inv(const dimensionedSphericalTensor &dt)
const DynamicList< label > & lambda() const
List of indices of the parent of each body.
label masterID() const
Return the master body Id.
bool merged(label bodyID) const
Return true if the body with given ID has been merged with a parent.
bool unitQuaternions() const
Return true if any of the joints using quaternions.
const word & name() const
Return the body name.
vector masterPoint(const label bodyID, const vector &p) const
const PtrList< joint > & joints() const
Return the list of joints in the model.
label nBodies() const
Return the number of bodies in the model (bodies().size())
HashTable< label, word > bodyIDs_
Lookup-table of the IDs of the bodies.
label nDoF() const
Return the number of degrees of freedom of the model.
DynamicList< spatialVector > v_
The spatial velocity of the bodies.
PtrList< joint > joints_
Each body it attached with a joint which are held on this list.
PtrList< rigidBody > bodies_
List of the bodies.
A 1D vector of objects of type <T> that resizes itself as necessary to accept the new objects...
const spatialVector & v(const label i) const
Return the spatial velocity of the bodies.
label mergedBodyIndex(const label mergedBodyID) const
Return the index of the merged body in the mergedBody list.
A class for handling words, derived from string.
SpatialVector< scalar > spatialVector
SpatialVector of scalars.
label nDoF_
The number of degrees of freedom of the model.
const vector & g() const
Return the acceleration due to gravity.
PtrList< rigidBody > bodies() const
Return the list of the bodies in the model.
errorManip< error > abort(error &err)
label master(label bodyID) const
Return the ID of the master body for a sub-body otherwise.
DynamicList< label > lambda_
List of indices of the parent of each body.
void T(FieldField< Field, Type > &f1, const FieldField< Field, Type > &f2)
bool unitQuaternions_
True if any of the joints using quaternions.
label mergedBodyID(const label mergedBodyIndex) const
Return the merged body ID for the given merged body index.
PtrList< subBody > mergedBodies_
Bodies may be merged into existing bodies, the inertia of which is.
const rigidBodyInertia & I(const label i) const
Return the inertia of body i.
const word & name(const label bodyID) const
Return the name of body with the given ID.
vector g_
Acceleration due to gravity.