34 const scalar mBy12 =
m/12.0;
35 const scalar mSqrLx = mBy12*
sqr(
L.
x());
36 const scalar mSqrLy = mBy12*
sqr(
L.
y());
37 const scalar mSqrLz = mBy12*
sqr(
L.
z());
41 mSqrLy + mSqrLz, 0, 0,
72 const scalar
m(
dict.lookup<scalar>(
"mass"));
cuboid(const word &name, const scalar m, const vector &c, const vector &L)
Construct from name, mass, centre of mass and lengths of the sides.
const vector & L() const
Return the lengths of the sides of the cuboid.
This class represents the linear and angular inertia of a rigid body by the mass, centre of mass and ...
const vector & c() const
Return the centre of mass of the rigid-body.
rigidBodyInertia()
Null constructor, initialises to zero.
scalar m() const
Return the mass of the rigid-body.
A list of keywords followed by any number of values (e.g. words and numbers) or sub-dictionaries.
A class for handling words, derived from string.
const dimensionedScalar c
Speed of light in a vacuum.
const unitSet & lookup(const word &unitName)
Lookup and return the named unit from the table.
SymmTensor< scalar > symmTensor
SymmTensor of scalars.
static const Identity< scalar > I
tmp< DimensionedField< typename outerProduct< Type, Type >::type, GeoMesh, Field >> sqr(const DimensionedField< Type, GeoMesh, PrimitiveField > &df)
Vector< scalar > vector
A scalar version of the templated Vector.
word name(const LagrangianState state)
Return a string representation of a Lagrangian state enumeration.