KratosMultiphysics
KRATOS Multiphysics (Kratos) is a framework for building parallel, multi-disciplinary simulation software, aiming at modularity, extensibility, and high performance. Kratos is written in C++, and counts with an extensive Python interface.
Classes | List of all members
Kratos::ParametricAffineTransform Class Reference

Class for applying parametrically defined affine transformations. More...

#include <parametric_affine_transform.h>

Inheritance diagram for Kratos::ParametricAffineTransform:
Collaboration diagram for Kratos::ParametricAffineTransform:

Public Member Functions

Life Cycle
 ParametricAffineTransform (const Parameters axis, const Parameters angle, const Parameters referencePoint, const Parameters translationVector)
 Construct via axis & angle. More...
 
 ParametricAffineTransform (const Parameters eulerAngles, const Parameters referencePoint, const Parameters translationVector)
 Construct via euler angles. More...
 
Operations
array_1d< double, 3 > Apply (const array_1d< double, 3 > &rPoint, const double t, const double X=0.0, const double Y=0.0, const double Z=0.0)
 Evaluate the transformation at the given location and apply it to a position vector, returning its transformed version. More...
 

Type definitions

using FunctionType = GenericFunctionUtility
 
 KRATOS_CLASS_POINTER_DEFINITION (ParametricAffineTransform)
 

Additional Inherited Members

- Protected Member Functions inherited from Kratos::AffineTransform
 KRATOS_CLASS_POINTER_DEFINITION (AffineTransform)
 
 AffineTransform ()
 Default constructor sets up an identity transform. More...
 
 AffineTransform (const array_1d< double, 3 > &rAxis, const double angle, const array_1d< double, 3 > &rReferencePoint, const array_1d< double, 3 > &rTranslationVector)
 Construct from axis and angle. More...
 
 AffineTransform (const array_1d< double, 3 > &rEulerAngles, const array_1d< double, 3 > &rReferencePoint, const array_1d< double, 3 > &rTranslationVector)
 Construct from euler angles. More...
 
 AffineTransform (const Quaternion< double > &rQuaternion, const array_1d< double, 3 > &rReferencePoint, const array_1d< double, 3 > &rTranslationVector)
 Construct from a quaternion. More...
 
void SetRotation (const array_1d< double, 3 > &rAxis, const double angle, const array_1d< double, 3 > &rReferencePoint)
 Set rotation from an axis and an angle. More...
 
void SetRotation (const array_1d< double, 3 > &rEulerAngles, const array_1d< double, 3 > &rReferencePoint)
 Set rotation from euler angles. More...
 
void SetRotation (const Quaternion< double > &rQuaternion, const array_1d< double, 3 > &rReferencePoint)
 Set rotation from a quaternion. More...
 
void SetTranslation (const array_1d< double, 3 > &rTranslationVector)
 Set translation part of the transformation. More...
 
array_1d< double, 3 > Apply (const array_1d< double, 3 > &rPoint) const
 Return the transformed version of the input vector. More...
 
- Protected Attributes inherited from Kratos::AffineTransform
array_1d< double, 3 > mReferencePoint
 
array_1d< double, 3 > mTranslationVector
 
Matrix mRotationMatrix
 

Detailed Description

Class for applying parametrically defined affine transformations.

see AffineTransform for transform conventions. Every transform parameter is parsed from an input Parameters to a GenericFunctionUtility that is evaluated on each application of the transform.

Member Typedef Documentation

◆ FunctionType

Constructor & Destructor Documentation

◆ ParametricAffineTransform() [1/2]

Kratos::ParametricAffineTransform::ParametricAffineTransform ( const Parameters  axis,
const Parameters  angle,
const Parameters  referencePoint,
const Parameters  translationVector 
)

Construct via axis & angle.

Parameters
rAxisaxis of rotation (array of size 3)
rAngleangle of rotation (in radians, scalar)
rReferencePointa point on the axis of rotation (array of size 3)
rTranslationVectortranslation vector (array of size 3)

◆ ParametricAffineTransform() [2/2]

Kratos::ParametricAffineTransform::ParametricAffineTransform ( const Parameters  eulerAngles,
const Parameters  referencePoint,
const Parameters  translationVector 
)

Construct via euler angles.

Parameters
rEulerAngleseuler angles (radians, array of size 3)
rReferencePointorigin of rotation (array of size 3)
rTranslationVectortranslation vector (array of size 3)
Note
The euler angles follow the convention specified by Quaternion (Z, -X', Z")

Member Function Documentation

◆ Apply()

array_1d< double, 3 > Kratos::ParametricAffineTransform::Apply ( const array_1d< double, 3 > &  rPoint,
const double  t,
const double  X = 0.0,
const double  Y = 0.0,
const double  Z = 0.0 
)

Evaluate the transformation at the given location and apply it to a position vector, returning its transformed version.

Parameters
rPointpoint to be transformed; it also acts as the current position input to GenericFunctionUtility.
ttime, see GenericFunctionUtility.
Xinitial x-coordinate, see GenericFunctionUtility.
Yinitial y-coordinate, see GenericFunctionUtility.
Zinitial z-coordinate, see GenericFunctionUtility.
Warning
This function is not thread-safe (BasicGenericFunctionUtility is mutated on each call).

◆ KRATOS_CLASS_POINTER_DEFINITION()

Kratos::ParametricAffineTransform::KRATOS_CLASS_POINTER_DEFINITION ( ParametricAffineTransform  )

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