Class OrientationByCartesianAngles
- Namespace
- VirtualLabAPI.Core.Numerics
- Assembly
- VirtualLabAPI.dll
A class for defining orientations by Cartesian angles, i.e. the angles between the projection of the direction to be defined onto the x-z-plane and the z-axis (alpha), and between the projection of the direction to be defined onto the y-z-plane and the z-axis (beta).
[Serializable]
public class OrientationByCartesianAngles : OrientationDefinitionBase, IEquatable<IObjectBase>, ISerializable, IDeserializationCallback, ICloneable
- Inheritance
-
ObjectBaseSerializableObjectBaseManualSerializationOrientationByCartesianAngles
- Implements
-
IEquatable<IObjectBase>
- Inherited Members
Constructors
OrientationByCartesianAngles()
Default constructor, setting alpha, beta and zeta to zero.
public OrientationByCartesianAngles()
OrientationByCartesianAngles(double, double)
Constructor with the Cartesian angles only.
public OrientationByCartesianAngles(double alpha, double beta)
Parameters
alphadoubleAngle between the projection of the direction to be defined onto the x-z-plane and the z-axis.
betadoubleAngle between the projection of the direction to be defined onto the y-z-plane and the z-axis.
OrientationByCartesianAngles(double, double, double)
Constructor with all angles.
public OrientationByCartesianAngles(double alpha, double beta, double zeta)
Parameters
alphadoubleAngle between the projection of the direction to be defined onto the x-z-plane and the z-axis.
betadoubleAngle between the projection of the direction to be defined onto the y-z-plane and the z-axis.
zetadoubleAngle zeta which is a rotation about the z-axis.
OrientationByCartesianAngles(double, double, double, bool)
Constructor with all parameters.
public OrientationByCartesianAngles(double alpha, double beta, double zeta, bool cartesianAnglesApplicationBeforeZetaRotation)
Parameters
alphadoubleAngle between the projection of the direction to be defined onto the x-z-plane and the z-axis.
betadoubleAngle between the projection of the direction to be defined onto the y-z-plane and the z-axis.
zetadoubleAngle zeta which is a rotation about the z-axis.
cartesianAnglesApplicationBeforeZetaRotationboolFlag, if the inclination of the z-axis by applying the direction angles shall be done before the rotation about the z-axis (by AngleZeta).
OrientationByCartesianAngles(OrientationByCartesianAngles)
Copy constructor.
public OrientationByCartesianAngles(OrientationByCartesianAngles orientationToCopy)
Parameters
orientationToCopyOrientationByCartesianAnglesOrientation object to copy.
Properties
AngleAlpha
Gets and sets the Cartesian angle alpha, which is the angle between the z-axis and the projection of the direction to be defined onto the x-z-plane.
public double AngleAlpha { get; set; }
Property Value
AngleBeta
Gets and sets the Cartesian angle beta, which is the angle between the projection of the direction to be defined onto the y-z-plane and the z-axis.
public double AngleBeta { get; set; }
Property Value
AngleZeta
Gets and sets the angle zeta which is a rotation about the z-axis. This rotation can be performed either before or after applying the direction angles, which is defined by CartesianAnglesApplicationBeforeZetaRotation. If this rotation is performed first, the flag AnglesReferToCSRotatedByZeta indicates, if the direction angles refer to the not rotated CS anyway.
public double AngleZeta { get; set; }
Property Value
CartesianAnglesApplicationBeforeZetaRotation
Gets or sets if the inclination of the z-axis by applying the direction angles shall be done before the rotation about the z-axis (by AngleZeta).
public bool CartesianAnglesApplicationBeforeZetaRotation { get; set; }
Property Value
DefinitionType
Gets the OrientationDefinitionType associated this orientation.
public override OrientationDefinitionType DefinitionType { get; }
Property Value
ListOfRotations
Gets a list of simple rotations, describing the complete rotation as a sequence.
public override List<SimpleRotation> ListOfRotations { get; }
Property Value
ParameterRunParameters
Gets all available parameters. For variable parameters (i.e. those double and int parameters which can be used in the Parameter Run, Parametric Optimization and so on) add a VaryParameterInfo object (derived from Parameter class) to the returned list.
public override List<Parameter> ParameterRunParameters { get; }
Property Value
- List<Parameter>
Methods
Clone()
Creates a new object that is a copy of the current instance.
public override object Clone()
Returns
- object
A new object that is a copy of this instance.
CorrespondingQuaternion()
Gets the quaternion corresponding to this orientation definition.
public override Quaternion CorrespondingQuaternion()
Returns
- Quaternion
The quaternion corresponding to this orientation definition.
Equals(object, EqualityIntent)
Determines whether the specified object is equal to this instance. Please note: If just the resulting orientation of this and the otherObject shall be compared, the method IsEquivalent of the base class should be used.
public override bool Equals(object otherObject, EqualityIntent equalityIntent)
Parameters
otherObjectobjectThe object to compare with this instance.
equalityIntentEqualityIntentDefines what kind of equality you want to check when comparing two objects, for example all values or physical equality.
Returns
SetCartesianAngles(double, double)
Sets the direction angles alpha, beta and gamma. The squared cosines of alpha, beta and gamma have to sum to 1.
public void SetCartesianAngles(double alpha, double beta)
Parameters
alphadoubleAngle between x-axis and the direction to define.
betadoubleAngle between y-axis and the direction to define.
ToString()
Overridden ToString method.
public override string ToString()