A coordinate rotation specified per local axes and the base class for other rotation specifications. More...
#include <meshTools/coordinateRotation.H>
A coordinate rotation specified per local axes and the base class for other rotation specifications.
The rotation is defined by a combination of local vectors (e1/e2), (e2/e3) or (e3/e1). Any nonorthogonality will be absorbed into the second vector.
For convenience, the dictionary constructor forms allow a few shortcuts:
type is not otherwise specified, the type axes is implicitSpecifying the rotation by an EulerCoordinateRotation (type "EulerRotation") or by a STARCDCoordinateRotation (type "STARCDRotation") requires the coordinateRotation sub-dictionary.
coordinateRotation
{
typeSTARCDRotation
rotation(0 0 90);
}
the rotation angles are in degrees, unless otherwise explictly specified:
coordinateRotation
{
typeSTARCDRotation
degrees false;
rotation(0 0 3.141592654);
}
axis (corresponding to e3) and a direction (corresponding to e1), is allowed for backwards compatibility, but this terminology is generally a bit confusing.Definition at line 87 of file coordinateRotation.H.
Inheritance diagram for coordinateRotation:
Collaboration diagram for coordinateRotation:Public Member Functions | |
| TypeName ("coordinateRotation") | |
| Runtime type information. | |
| coordinateRotation () | |
| Construct null. | |
| coordinateRotation (const vector &axis, const vector &dir) | |
| Construct from 2 axes. | |
| coordinateRotation (const dictionary &) | |
| Construct from dictionary. | |
| autoPtr< coordinateRotation > | clone () const |
| Return clone. | |
| declareRunTimeSelectionTable (autoPtr, coordinateRotation, dictionary,(const dictionary &dict),(dict)) | |
| virtual | ~coordinateRotation () |
| const tensor & | R () const |
| Return local-to-global transformation tensor. | |
| const vector | e1 () const |
| Return local Cartesian x-axis. | |
| const vector | e2 () const |
| Return local Cartesian y-axis. | |
| const vector | e3 () const |
| Return local Cartesian z-axis. | |
| void | operator= (const dictionary &) |
| assign from dictionary | |
Public Member Functions inherited from Tensor< Cmpt > | |
| Tensor () | |
| Construct null. | |
| Tensor (const VectorSpace< Tensor< Cmpt >, Cmpt, 9 > &) | |
| Construct given VectorSpace. | |
| Tensor (const SphericalTensor< Cmpt > &) | |
| Construct given SphericalTensor. | |
| Tensor (const SymmTensor< Cmpt > &) | |
| Construct given SymmTensor. | |
| Tensor (const Vector< Cmpt > &x, const Vector< Cmpt > &y, const Vector< Cmpt > &z) | |
| Construct given the three vectors. | |
| Tensor (const Cmpt txx, const Cmpt txy, const Cmpt txz, const Cmpt tyx, const Cmpt tyy, const Cmpt tyz, const Cmpt tzx, const Cmpt tzy, const Cmpt tzz) | |
| Construct given the nine components. | |
| Tensor (Istream &) | |
| Construct from Istream. | |
| const Cmpt & | xx () const |
| const Cmpt & | xy () const |
| const Cmpt & | xz () const |
| const Cmpt & | yx () const |
| const Cmpt & | yy () const |
| const Cmpt & | yz () const |
| const Cmpt & | zx () const |
| const Cmpt & | zy () const |
| const Cmpt & | zz () const |
| Cmpt & | xx () |
| Cmpt & | xy () |
| Cmpt & | xz () |
| Cmpt & | yx () |
| Cmpt & | yy () |
| Cmpt & | yz () |
| Cmpt & | zx () |
| Cmpt & | zy () |
| Cmpt & | zz () |
| const Vector< Cmpt > | x () const |
| const Vector< Cmpt > | y () const |
| const Vector< Cmpt > | z () const |
| Tensor< Cmpt > | T () const |
| Transpose. | |
| void | operator= (const SphericalTensor< Cmpt > &) |
| Assign to a SphericalTensor. | |
| void | operator= (const SymmTensor< Cmpt > &) |
| Assign to a SymmTensor. | |
Public Member Functions inherited from VectorSpace< Tensor< Cmpt >, Cmpt, 9 > | |
| VectorSpace () | |
| Construct null. | |
| VectorSpace (Istream &) | |
| Construct from Istream. | |
| VectorSpace (const VectorSpace< Tensor< Cmpt >, Cmpt, nCmpt > &) | |
| Construct as copy. | |
| label | size () const |
| Return the number of elements in the VectorSpace = nCmpt. | |
| const Cmpt & | component (const direction) const |
| Cmpt & | component (const direction) |
| void | component (Cmpt &, const direction) const |
| void | replace (const direction, const Cmpt &) |
| const Cmpt & | operator[] (const direction) const |
| Cmpt & | operator[] (const direction) |
| void | operator= (const VectorSpace< Tensor< Cmpt >, Cmpt, nCmpt > &) |
| void | operator+= (const VectorSpace< Tensor< Cmpt >, Cmpt, nCmpt > &) |
| void | operator-= (const VectorSpace< Tensor< Cmpt >, Cmpt, nCmpt > &) |
| void | operator*= (const scalar) |
| void | operator/= (const scalar) |
Static Public Member Functions | |
| static autoPtr < coordinateRotation > | New (const dictionary &dict) |
| Select constructed from Istream. | |
Additional Inherited Members | |
Public Types inherited from Tensor< Cmpt > | |
| enum | { rank = 2 } |
| enum | components { XX, XY, XZ, YX, YY, YZ, ZX, ZY, ZZ } |
| Component labeling enumeration. More... | |
| typedef Tensor< label > | labelType |
| Equivalent type of labels used for valid component indexing. | |
Public Types inherited from VectorSpace< Tensor< Cmpt >, Cmpt, 9 > | |
| enum | |
| typedef Cmpt | cmptType |
| Component type. | |
Static Public Attributes inherited from Tensor< Cmpt > | |
| static const char *const | typeName = "labelTensor" |
| static const char * | componentNames [] |
| static const Tensor | zero |
| static const Tensor | one |
| static const Tensor | max |
| static const Tensor | min |
Construct null.
Definition at line 96 of file coordinateRotation.C.
Referenced by coordinateRotation::clone().
| coordinateRotation | ( | const vector & | axis, |
| const vector & | dir | ||
| ) |
Construct from 2 axes.
Definition at line 103 of file coordinateRotation.C.
| coordinateRotation | ( | const dictionary & | dict | ) |
Construct from dictionary.
Definition at line 115 of file coordinateRotation.C.
|
inlinevirtual |
Definition at line 162 of file coordinateRotation.H.
| TypeName | ( | "coordinateRotation" | ) |
Runtime type information.
|
inline |
Return clone.
Definition at line 132 of file coordinateRotation.H.
References coordinateRotation::coordinateRotation().
| declareRunTimeSelectionTable | ( | autoPtr | , |
| coordinateRotation | , | ||
| dictionary | , | ||
| (const dictionary &dict) | , | ||
| (dict) | |||
| ) |
|
static |
Select constructed from Istream.
Definition at line 127 of file coordinateRotation.C.
References Foam::endl(), Foam::exit(), Foam::FatalIOError, FatalIOErrorIn, Foam::nl, Foam::Pout, and dictionary::readIfPresent().
Referenced by coordinateSystem::operator=().
|
inline |
Return local-to-global transformation tensor.
Definition at line 169 of file coordinateRotation.H.
|
inline |
Return local Cartesian x-axis.
Definition at line 175 of file coordinateRotation.H.
References Tensor< Cmpt >::T().
|
inline |
Return local Cartesian y-axis.
Definition at line 181 of file coordinateRotation.H.
References Tensor< Cmpt >::T().
|
inline |
Return local Cartesian z-axis.
Definition at line 187 of file coordinateRotation.H.
References Tensor< Cmpt >::T().
| void operator= | ( | const dictionary & | rhs | ) |
assign from dictionary
Definition at line 172 of file coordinateRotation.C.
References Foam::endl(), dictionary::found(), SphericalTensor< Cmpt >::I, dictionary::lookup(), Tensor< Cmpt >::operator=(), Foam::Pout, dictionary::readIfPresent(), and dictionary::subDict().