Based on definitions in chapter 2 of the book:
Featherstone, R. (2008).
Rigid body dynamics algorithms.
Springer.
This work is sponsored by Carnegie Wave Energy Ltd
The particular rotation sequence is specified via the enumeration:
//- Euler-angle rotation sequence
enum rotationSequence
{
ZYX, ZYZ, ZXY, ZXZ, YXZ, YXY, YZX, YZY, XYZ, XYX, XZY, XZX
};
and provided as an argument to the constructor from Euler-angles
//- Construct a quaternion given the three Euler angles:
inline quaternion
(
const rotationSequence rs,
const vector& angles
);
and conversion to Euler-angles:
//- Return a vector of euler angles corresponding to the
// specified rotation sequence
inline vector eulerAngles(const rotationSequence rs) const;
Provides '(i, j)' element access and general forms of inner and outer
products, transpose etc. for square and rectangular VectorSpaces.
VectorSpaces default to be column-vectors as before whereas row-vectors
may be represented as 1xn MatrixSpaces. In the future it may be
preferable to create a specializations of VectorSpace for column- and
maybe row-vectors but it would add complexity to MatrixSpace to handle
all the type combinations.
Tensor is now a 3x3 specialization of MatrixSpace.
Sub-block const and non-const access is provided via the
'.block<SubTensor, RowStart, ColStart>()' member functions. Consistent
sub-block access is also provide for VectorSpace so that columns of
MatrixSpaces may be accessed and substituted.
These new classes will be used to create a more extensive set of
primitive vector and tensor types over the next few weeks.
Henry G. Weller
CFD Direct
Foam::direction is an unsigned type which makes it easier for the
compiler to pickup and report errors in the instantiation of
VectorSpaces and associated types.
Wall-velocity condition to be used in conjunction with the single rotating
frame (SRF) model (see: FOAM::SRFModel)
The condition applies the appropriate rotation transformation in time and
space to determine the local SRF velocity of the wall.
\f[
U_p = - U_{p,srf}
\f]
where
\vartable
U_p = patch velocity [m/s]
U_{p,srf} = SRF velocity
\endvartable
The normal component of \f$ U_p \f$ is removed to ensure 0 wall-flux even
if the wall patch faces are irregular.
\heading Patch usage
Example of the boundary condition specification:
\verbatim
myPatch
{
type SRFWallVelocity;
value uniform (0 0 0); // Initial value
}
\endverbatim
DebugInfo:
Report an information message using Foam::Info if the local debug
switch is true
DebugInFunction:
Report an information message using Foam::Info for FUNCTION_NAME in
file __FILE__ at line __LINE__ if the local debug switch is true
which reduces the number of potential problems with the reuse of
temporary objects.
In order to avoid unnecessary creation of tmp's referring to temporary
objects the assignment operator now transfers ownership of the object
and resets the argument.
The deprecated non-const tmp functionality is now on the compiler switch
NON_CONST_TMP which can be enabled by adding -DNON_CONST_TMP to EXE_INC
in the Make/options file. However, it is recommended to upgrade all
code to the new safer tmp by using the '.ref()' member function rather
than the non-const '()' dereference operator when non-const access to
the temporary object is required.
Please report any problems on Mantis.
Henry G. Weller
CFD Direct.