Loading...
Searching...
No Matches
euler Class Reference

A coordinateRotation defined in the z-x-z (intrinsic) Euler convention. More...

#include <EulerCoordinateRotation.H>

Inheritance diagram for euler:
Collaboration diagram for euler:

Public Types

using eulerOrder = quaternion::eulerOrder
 Euler-angle rotation order.

Public Member Functions

 TypeNameNoDebug ("euler")
 Runtime type information.
 euler ()
 Default construct - an identity transform.
 euler (const euler &crot)
 Copy construct.
 euler (const vector &angles, bool degrees)
 Construct from Euler intrinsic rotation angles (z-x-z).
 euler (scalar angle1, scalar angle2, scalar angle3, bool degrees)
 Construct from Euler intrinsic rotation angles (z-x-z).
 euler (const dictionary &dict)
 Construct from dictionary.
autoPtr< coordinateRotationclone () const
 Return clone.
virtual ~euler ()=default
 Destructor.
virtual void clear ()
 Reset specification.
virtual tensor R () const
 The rotation tensor calculated for the specified Euler angles.
virtual void write (Ostream &os) const
 Write information.
virtual void writeEntry (const word &keyword, Ostream &os) const
 Write dictionary entry.
Public Member Functions inherited from coordinateRotation
 TypeNameNoDebug ("coordinateRotation")
 Runtime type information.
 declareRunTimeSelectionTable (autoPtr, coordinateRotation, dictionary,(const dictionary &dict),(dict))
virtual ~coordinateRotation ()=default
 Destructor.

Static Public Member Functions

static tensor rotation (const vector &angles, bool degrees=false)
 Rotation tensor calculated for the intrinsic Euler angles in z-x-z order.
static tensor rotation (const eulerOrder order, const vector &angles, bool degrees=false)
 Rotation tensor calculated for given order and angles.
Static Public Member Functions inherited from coordinateRotation
template<class Derived>
static autoPtr< coordinateRotationClone (const Derived &crot)
 Clone a coordinate rotation.
static autoPtr< coordinateRotationNew (const word &modelType, const dictionary &dict)
 Select construct the specified coordinate rotation type.
static autoPtr< coordinateRotationNew (const dictionary &dict)
 Select construct from dictionary (requires the "type" entry).

Additional Inherited Members

Static Protected Member Functions inherited from coordinateRotation
static vector findOrthogonal (const vector &axis)
 Determine best-guess for an orthogonal axis.

Detailed Description

A coordinateRotation defined in the z-x-z (intrinsic) Euler convention.

The 3 rotations are defined in the Euler intrinsic convention (around Z, around X' and around Z''). The order of the parameter arguments matches this rotation order.

For reference and illustration, see https://en.wikipedia.org/wiki/Euler_angles

rotation
{
    type    euler;
    angles  (0 0 180);
}


Dictionary entries

Property Description Reqd Default
type Type name: euler yes
angles Rotation angles (usually z-x-z order) yes
degrees Angles are in degrees no true
order Rotation order no zxz
Note
The rotation order is usually z-x-z, but can also be something like "rollPitchYaw" etc. Also accepts "EulerRotation" (OpenFOAM-v1806) for the type.
Source files

Definition at line 104 of file EulerCoordinateRotation.H.

Member Typedef Documentation

◆ eulerOrder

Euler-angle rotation order.

Definition at line 115 of file EulerCoordinateRotation.H.

Constructor & Destructor Documentation

◆ euler() [1/5]

euler ( )

Default construct - an identity transform.

Definition at line 246 of file EulerCoordinateRotation.C.

References Foam::Zero.

Referenced by euler(), and TypeNameNoDebug().

Here is the caller graph for this function:

◆ euler() [2/5]

euler ( const euler & crot)

Copy construct.

Definition at line 255 of file EulerCoordinateRotation.C.

References euler().

Here is the call graph for this function:

◆ euler() [3/5]

euler ( const vector & angles,
bool degrees )

Construct from Euler intrinsic rotation angles (z-x-z).

Definition at line 264 of file EulerCoordinateRotation.C.

◆ euler() [4/5]

euler ( scalar angle1,
scalar angle2,
scalar angle3,
bool degrees )

Construct from Euler intrinsic rotation angles (z-x-z).

Definition at line 277 of file EulerCoordinateRotation.C.

◆ euler() [5/5]

euler ( const dictionary & dict)
explicit

Construct from dictionary.

Definition at line 292 of file EulerCoordinateRotation.C.

References dict.

◆ ~euler()

virtual ~euler ( )
virtualdefault

Destructor.

References os().

Here is the call graph for this function:

Member Function Documentation

◆ TypeNameNoDebug()

TypeNameNoDebug ( "euler" )

Runtime type information.

References dict, and euler().

Here is the call graph for this function:

◆ clone()

autoPtr< coordinateRotation > clone ( ) const
inlinevirtual

Return clone.

Implements coordinateRotation.

Definition at line 176 of file EulerCoordinateRotation.H.

References coordinateRotation::Clone().

Here is the call graph for this function:

◆ rotation() [1/2]

Foam::tensor rotation ( const vector & angles,
bool degrees = false )
static

Rotation tensor calculated for the intrinsic Euler angles in z-x-z order.

Definition at line 234 of file EulerCoordinateRotation.C.

References rotation().

Referenced by R(), rotation(), and starcd::rotation().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ rotation() [2/2]

Foam::tensor rotation ( const eulerOrder order,
const vector & angles,
bool degrees = false )
static

Rotation tensor calculated for given order and angles.

Definition at line 61 of file EulerCoordinateRotation.C.

References Foam::abort(), Foam::cos(), Foam::degToRad(), Foam::FatalError, FatalErrorInFunction, SphericalTensor< scalar >::I, Foam::sin(), Vector< Cmpt >::x(), Vector< Cmpt >::y(), and Vector< Cmpt >::z().

Here is the call graph for this function:

◆ clear()

void clear ( )
virtual

Reset specification.

Implements coordinateRotation.

Definition at line 311 of file EulerCoordinateRotation.C.

References Foam::Zero.

◆ R()

Foam::tensor R ( ) const
virtual

The rotation tensor calculated for the specified Euler angles.

Implements coordinateRotation.

Definition at line 318 of file EulerCoordinateRotation.C.

References rotation().

Here is the call graph for this function:

◆ write()

void write ( Ostream & os) const
virtual

Write information.

Implements coordinateRotation.

Definition at line 324 of file EulerCoordinateRotation.C.

References os().

Here is the call graph for this function:

◆ writeEntry()

void writeEntry ( const word & keyword,
Ostream & os ) const
virtual

Write dictionary entry.

Implements coordinateRotation.

Definition at line 330 of file EulerCoordinateRotation.C.

References quaternion::eulerOrderNames, os(), and Foam::type().

Here is the call graph for this function:

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