Programming Reference for VirtualLab™
5.4
|
Classes | |
class | SystemBaseVectors |
Class for base vectors. More... | |
Public Member Functions | |
PositionedLine | AxisAsPositionedLine (AxisDirection chosenAxis) |
CartesianCoordinateSystem () | |
CartesianCoordinateSystem (IProvidesPositioningReferences positioningReferenceProvider, string positioningReferenceKey) | |
CartesianCoordinateSystem (Position origin) | |
CartesianCoordinateSystem (CartesianCoordinateSystem cs) | |
CartesianCoordinateSystem (Position origin, Vector3D xAxis, Vector3D yAxis, Vector3D zAxis) | |
CartesianCoordinateSystem (Position origin, double eulerPsi, double eulerTheta, double eulerPhi) | |
CartesianCoordinateSystem (Position origin, EulerAnglesSet eulerAngles) | |
CartesianCoordinateSystem (Position origin, SystemBaseVectors axes) | |
CartesianCoordinateSystem (SerializationInfo info, StreamingContext context) | |
object | Clone () |
void | GetGlobalTransformationParameters (out Matrix3x3D globalRotationMatrix, out Vector3D globalOriginPos) |
CartesianCoordinateSystem | GetRotatedAndTranslatedCoordinateSystem (Vector3D offset, Matrix3x3D rotation) |
void | GetRotationAsSphericalAnglesOfZAxis (out double theta, out double phi) |
void | OnCoordinateSystemChanged () |
void | SetPositioningReference (IProvidesPositioningReferences referenceProvider, string key) |
override string | ToString () |
Vector3D | TransformInternalPosition2PositionInReferenceCS (Vector3D internalPos) |
Vector3D | TransformPositionInReferenceCS2InternalPosition (Vector3D externalPos) |
Static Public Member Functions | |
static CartesianCoordinateSystem | GetCSForReflection (CartesianCoordinateSystem coordinateSystemInput) |
static CartesianCoordinateSystem | GetCSFromAxisRotationsSequence (Position origin, AxisRotationSequence sequence) |
static CartesianCoordinateSystem | GetCSFromCartesianAnglesOfZAxis (Position origin, double zeta, double alpha, double beta, bool inclinationFirst, bool zAxisDefinedInRotatedSystem) |
static CartesianCoordinateSystem | GetCSFromDirectionAnglesOfZAxis (Position origin, double zeta, double alpha, double beta, double gamma, bool inclinationFirst, bool zAxisDefinedInRotatedSystem) |
static CartesianCoordinateSystem | GetCSFromDirectionOfZAxis (Position origin, double zeta, Vector3D directionOfZAxis, bool inclinationFirst, bool zAxisDefinedInRotatedSystem) |
static CartesianCoordinateSystem | GetCSFromIOrientationDefinition (Position origin, IOrientationDefinition orientationDefinition) |
static CartesianCoordinateSystem | GetCSFromSphericalAnglesOfZAxis (Position origin, double zeta, double zPhi, double zTheta, bool inclinationFirst, bool zAxisInclinatedInRotatedSystem) |
static bool | operator!= (CartesianCoordinateSystem cs1, CartesianCoordinateSystem cs2) |
static bool | operator== (CartesianCoordinateSystem cs1, CartesianCoordinateSystem cs2) |
static Matrix3x3D | RotationMatrixForArbitraryAxis (Vector3D rotationAxis, double angle) |
static Matrix3x3D | RotationMatrixForRotationAngle (PhysicalValue rotAngle) |
static Matrix3x3D | RotationMatrixForXAxis (double angle) |
static Matrix3x3D | RotationMatrixForYAxis (double angle) |
static Matrix3x3D | RotationMatrixForZAxis (double angle) |
Properties | |
SystemBaseVectors | Axes [get, set] |
CartesianCoordinateSystem | GetPositioningReference [get] |
bool | IsDefinedAbsolutely [get] |
Position | Origin [get, set] |
string | PositioningReferenceKey [get] |
IProvidesPositioningReferences | PositioningReferenceProvider [get] |
Events | |
EventHandler | CoordinateSystemChanged |
Default constructor, creating a new CartesianCoordinateSystem that is defined absolutely, and identical to the global coordinate system.
CartesianCoordinateSystem | ( | IProvidesPositioningReferences | positioningReferenceProvider, |
string | positioningReferenceKey | ||
) |
Constructor, creating a new CartesianCoordinateSystem that is defined in reference to a given reference cs, it lies at (0,0,0) and is not rotated to this reference.
CartesianCoordinateSystem | ( | Position | origin | ) |
Constructor for a Cartesian coordinate system that is translated but not rotated with respect to the reference coordinate system. The pointer to the reference coordinate system is stored in variable origin.
origin | Position of the origin with respect to the reference coordinate system, that is set via origin.ReferenceCoordinateSystem. |
Copy constructor.
cs | system to be copied. |
CartesianCoordinateSystem | ( | Position | origin, |
Vector3D | xAxis, | ||
Vector3D | yAxis, | ||
Vector3D | zAxis | ||
) |
Constructor that uses a position for the origin and the new axes, which must be orthogonal and should be normalized (constructor will normalize them anyway)
origin | Position of the origin. |
xAxis | Direction cosine of the x-axis. |
yAxis | Direction cosine of the y-axis. |
zAxis | Direction cosine of the z-axis. |
CartesianCoordinateSystem | ( | Position | origin, |
double | eulerPsi, | ||
double | eulerTheta, | ||
double | eulerPhi | ||
) |
Constructor that uses a position and euler angles
origin | Position of the origin. |
eulerPsi | Euler angle Psi for rotation. |
eulerTheta | Euler angle Theta for rotation. |
eulerPhi | Euler angle Phi for rotation. |
CartesianCoordinateSystem | ( | Position | origin, |
EulerAnglesSet | eulerAngles | ||
) |
Constructor that uses a position and euler angles
origin | Position of the origin. |
eulerAngles | Set of Euler angles that describes orientation |
CartesianCoordinateSystem | ( | Position | origin, |
SystemBaseVectors | axes | ||
) |
Constructor that uses a Position and a SystemBaseVectors
origin | Position of origin |
axes | Directions of the axes |
CartesianCoordinateSystem | ( | SerializationInfo | info, |
StreamingContext | context | ||
) |
Deserialization constructor used for manual serialization
info | the info object used for deserialization |
context | the streaming context |
PositionedLine AxisAsPositionedLine | ( | AxisDirection | chosenAxis | ) |
Extracts one axis as positioned line
chosenAxis | Axis to extract |
object Clone | ( | ) |
Deep copy
|
static |
Gets a coordinate system which can be used for reflection
coordinateSystemInput | The coordinate system from the coordinate system for reflection is being generated. |
|
static |
Constructs a new cartesian coordinate system via axis rotation sequence
origin | Origin of coordinate system in reference coordinates. |
sequence | AxisRotationSequence that determines how to get the new coordinate system starting from its reference system. |
|
static |
Constructs a new cartesian coordinate system with respect to the reference cs (stored in origin) via z-rotation and cartesian angles for the z-axis: The orientation of the coordinate system results from the reference cs in 2 steps and this order (if inclinationFirst=false): (i) Rotation about z-axis with angle zeta - using the right-hand-rule (ii) Inclination of z-axis specified by cartesian angles or vice versa, if inclinationFirst=true: (i) Inclination of z-axis specified by cartesian angles (ii) Rotation about inclined z-axis by angle zeta - using the right-hand-rule
origin | Origin of coordinate system in reference coordinates. |
zeta | Angle (radian) of rotation about z-axis by using the right-hand-rule. |
alpha | Angle between the z-axis and the projection of the z-axis onto the x-z-plane |
beta | Angle between the z-axis and the projection of the z-axis onto the y-z-plane |
inclinationFirst | Flag to signal if z-axis is inclined first (true) or after rotation of z-axis (false). If true, parameter zAxisDefinedInRotatedSystem is ignored, as the z-axis must always be defined in the reference system, of course. |
zAxisDefinedInRotatedSystem | If false, directionOfZAxis defines the direction of the z-axis in the reference coordinate system. If true, directionOfZAxis defines the direction of the z-axis in the rotated coordinate system (rotation about z-axis by zeta). |
|
static |
Constructs a new cartesian coordinate system with respect to the reference cs (stored in origin) via z-rotation and direction angles: The orientation of the coordinate system results from the reference cs in 2 steps and this order (if inclinationFirst=false): (i) Rotation about z-axis with angle zeta - using the right-hand-rule (ii) Inclination of z-axis specified by direction angles alpha, beta, gamma with the positive x-, y- and z-axis of either the reference cs (zAxisDefinedInRotatedSystem==false) or the rotated cs (zAxisDefinedInRotatedSystem==true). or vice versa, if inclinationFirst=true: (i) Inclination of z-axis (ii) Rotation about inclined z-axis by angle zeta - using the right-hand-rule
origin | Origin of coordinate system in reference coordinates. |
zeta | Angle (in radian) of rotation about z-axis by using the right-hand-rule. |
alpha | Direction cosine angle alpha in radian: angle of new z-axis with positive x-axis. |
beta | Direction cosine beta in radian: angle of new z-axis with positive y-axis. |
gamma | Direction cosine beta in radian: angle of new z-axis with positive z-axis. |
inclinationFirst | Flag to signal if z-axis is inclined first (true) or after rotation of z-axis (false). If true, parameter zAxisDefinedInRotatedSystem is ignored, as it must always be defined in the reference system, of course. |
zAxisDefinedInRotatedSystem | If false, directionOfZAxis defines the direction of the z-axis in the reference coordinate system. If true, directionOfZAxis defines the direction of the z-axis in the rotated coordinate system (rotation about z-axis by zeta). |
|
static |
Constructs a new cartesian coordinate system with respect to the reference cs (stored in origin) via z-rotation and the direction vector of the z-axis: The orientation of the coordinate system results from the reference cs in 2 steps and this order (if inclinationFirst=false): (i) Rotation about z-axis with angle zeta - using the right-hand-rule (ii) Inclination of z-axis specified by new direction axis or vice versa, if inclinationFirst=true: (i) Inclination of z-axis specified by direction vector (ii) Rotation about inclined z-axis by angle zeta - using the right-hand-rule
origin | Origin of coordinate system in reference coordinates. |
zeta | Angle (radian) of rotation about z-axis by using the right-hand-rule. |
directionOfZAxis | Direction vector of new z-axis |
inclinationFirst | Flag to signal if z-axis is inclined first (true) or after rotation of z-axis (false). If true, parameter zAxisDefinedInRotatedSystem is ignored, as the z-axis must always be defined in the reference system, of course. |
zAxisDefinedInRotatedSystem | If false, directionOfZAxis defines the direction of the z-axis in the reference coordinate system. If true, directionOfZAxis defines the direction of the z-axis in the rotated coordinate system (rotation about z-axis by zeta). |
|
static |
Constructs a new cartesian coordinate system via any IOrientationDefinition
origin | Origin of coordinate system in reference coordinates. |
orientationDefinition | IOrientationDefinition that determines how to get the new coordinate system starting from its reference system. |
|
static |
Constructs a new cartesian coordinate system with respect to the reference cs (stored in origin) via z-rotation and spherical angles: The orientation of the coordinate system results from the reference cs in 2 steps and this order (if inclinationFirst=false): (i) Rotation about z-axis with angle zeta - using the right-hand-rule (ii) Inclination of z-axis by spherical angles phi and theta or vice versa, if inclinationFirst=true: (i) Inclination of z-axis by spherical angles phi and theta (ii) Rotation about inclined z-axis by angle zeta - using the right-hand-rule
origin | Origin of coordinate system in reference coordinates. |
zeta | Angle (radian) of rotation about z-axis by using the right-hand-rule. |
zPhi | Spherical angle phi in radian for inclination of z-axis. This angle starts at the x-axis (zPhi = 0), while the y-axis corresponds to zPhi = 90° |
zTheta | Spherical angle theta in radian for inclination of z-axis. |
inclinationFirst | Flag to signal if z-axis is inclined first (true) or after rotation of z-axis (false). If true, parameter zAxisDefinedInRotatedSystem is ignored, as the z-axis must always be defined in the reference system, of course. |
zAxisInclinatedInRotatedSystem | If false, the spherical angles describe the inclination of the z-axis in the reference coordinate system. If true, the spherical angles describe the inclination of the z-axis in the rotated coordinate system (rotation about z-axis by zeta). |
void GetGlobalTransformationParameters | ( | out Matrix3x3D | globalRotationMatrix, |
out Vector3D | globalOriginPos | ||
) |
Get the coordinate transformation parameters (rotation matrix and the origin position) with respect to the global coordinate system. A coordinate transformation from this cs (x') to the global cs (x) can be done by x = Rx' + o and vice versa: x' = R^T(x - o)
globalRotationMatrix | Global rotation matrix R. |
globalOrigin | Origin o of this coordinate system in global (absolute) coordinates. |
CartesianCoordinateSystem GetRotatedAndTranslatedCoordinateSystem | ( | Vector3D | offset, |
Matrix3x3D | rotation | ||
) |
Returns a new coordinate system that is rotated and translated by given values in reference to this and defined in reference to this.
offset | Translation distance, defined in the external CS |
rotation | Rotation matrix, defined in the external CS |
void GetRotationAsSphericalAnglesOfZAxis | ( | out double | theta, |
out double | phi | ||
) |
Gets the orientation of this by calculating the spere angles theta and phi for the z axis
theta | Sphere angle theta, i.e. the inclination of the z axis to the z axis of the reference CS. |
phi | Sphere angle phi, i.e. the azimuth angle of the z axis to the x axis of the reference CS |
void OnCoordinateSystemChanged | ( | ) |
Event throwing method
|
static |
Overloaded unequality operator
pos1 | First CartesianCoordinateSystem to compare |
pos2 | Second CartesianCoordinateSystem to compare |
|
static |
Overloaded equality operator
pos1 | First CartesianCoordinateSystem to compare |
pos2 | Second CartesianCoordinateSystem to compare |
|
static |
Calculates the rotation matrix for a arbitrary rotation axis and a rotation angle (by using the right-hand-rule). If a coordinate system shall be rotated, the transposed matrix has to be used.
rotationAxis | Rotation axis (unit vector) |
angle | Rotation angle. |
|
static |
Calculates the rotation matrix for a rotation about the x-, y-, or z-axis
rotAngle | A physical value that contains the rotation angle and the information (in the Comment), about what axis the rotation shall be done |
|
static |
Calculates the rotation matrix for a rotation about the x-axis
angle | Rotation angle |
|
static |
Calculates the rotation matrix for a rotation about the y-axis
angle | Rotation angle |
|
static |
Calculates the rotation matrix for a rotation about the z-axis
angle | Rotation angle |
void SetPositioningReference | ( | IProvidesPositioningReferences | referenceProvider, |
string | key | ||
) |
Method to set the PositioningReferenceProvider and the key for the coordinate system that serves as positioning reference
referenceProvider | Object which provides the coordinate system that serves as reference for this position. |
key | Key for the coordinate system (contained by PositioningReferenceProvider) which shall serve as reference for this position |
override string ToString | ( | ) |
method to generate a string description of the object
Vector3D TransformInternalPosition2PositionInReferenceCS | ( | Vector3D | internalPos | ) |
Transforms a given position in this CS to the reference CS.
internalPos | Position to transform |
Vector3D TransformPositionInReferenceCS2InternalPosition | ( | Vector3D | externalPos | ) |
Transforms a given position from the reference coordinate system to this CS.
externalPos | Position in the reference CS to transform |
|
getset |
Gets or sets the axes or base vectors of the coordinate system
|
get |
Property to get the coordinate system that serves as reference for this object
|
get |
Are the origin's position and the axes directions defined absolutely?
|
getset |
Gets or sets the origin of the coordinate system
|
get |
Get the key of the reference coordinate system for this
|
get |
Get the object that provides the reference coordinate system for this
EventHandler CoordinateSystemChanged |
Event that is thrown if the Coordinate System is changed