rotlib 1.0.0
Loading...
Searching...
No Matches
Euler angles

Functions

void euler_rotmat (const double euler[3], enum EulangSeq seq, const bool world, double *rotmat)
 Calculates the rotation matrix for a set of Euler angles.
void euler_shiftmat (const double euler[3], enum EulangSeq seq, const bool world, const bool forward, double *shiftmat)
 Calculates the shifter matrix for a set of Euler angles.
void euler_rotate_vectors (const int n, const double *v, const double euler[3], enum EulangSeq seq, const bool world, double *vrot)
 Rotates vectors with a set of Euler angles.
void euler_shift_vectors (const int n, const double *v, const double euler[3], enum EulangSeq seq, const bool world, const bool forward, double *vshift)
 Given two frames A and B such that the orientation of frame B with respect to frame A is given by three Euler angles, shifts vectors from A to B or B to A.
void euler_shift_tensor2 (const double *A, const double euler[3], enum EulangSeq seq, const bool world, const bool forward, double *Ashift)
 Given two frames A and B such that the orientation of frame B with respect to frame A is given by three Euler angles, shifts second-order tensors from A to B or B to A.
void euler_shift_tensor3 (const double *A, const double euler[3], enum EulangSeq seq, const bool world, const bool forward, double *Ashift)
 Given two frames A and B such that the orientation of frame B with respect to frame A is given by three Euler angles, shifts third-order tensors from A to B or B to A.
void euler_to_quat (const double euler[3], enum EulangSeq seq, const bool world, double q[4])
 Convert Euler angles to a unit quaternion.
void euler_to_aa (const double euler[3], enum EulangSeq seq, const bool world, double axis[3], double *angle)
 Convert Euler angles to an axis-angle representation.
void euler_to_dcm (const double euler[3], enum EulangSeq seq, const bool world, double *dcm)
 Convert Euler angles to a direction cosine matrix.
void euler_to_euler (const double euler[3], enum EulangSeq seq, const bool world, enum EulangSeq to_seq, const bool to_world, double to_euler[3])
 Converts Convert one set of Euler angles to another.

Detailed Description

Function Documentation

◆ euler_rotate_vectors()

void euler_rotate_vectors ( const int n,
const double * v,
const double euler[3],
enum EulangSeq seq,
const bool world,
double * vrot )

Rotates vectors with a set of Euler angles.

Parameters
[in]nNumber of rows of v.
[in]vn x 3 array whose rows are the vectors to rotate.
[in]eulerEuler angles.
[in]seqES_XYZ | ES_XZY | ES_YXZ | ES_YZX | ES_ZXY | ES_ZYX.
Sequence for Euler angles.
[in]worldWhether the Euler angles are with respect to the world frame or not.
[out]vrotn x 3 array whose rows are the rotated vectors.

◆ euler_rotmat()

void euler_rotmat ( const double euler[3],
enum EulangSeq seq,
const bool world,
double * rotmat )

Calculates the rotation matrix for a set of Euler angles.

Parameters
[in]eulerEuler angles.
[in]seqES_XYZ | ES_XZY | ES_YXZ | ES_YZX | ES_ZXY | ES_ZYX.
Sequence for Euler angles.
[in]worldWhether the Euler angles are with respect to the world frame or not.
[out]rotmat3 x 3 rotation matrix.

◆ euler_shift_tensor2()

void euler_shift_tensor2 ( const double * A,
const double euler[3],
enum EulangSeq seq,
const bool world,
const bool forward,
double * Ashift )

Given two frames A and B such that the orientation of frame B with respect to frame A is given by three Euler angles, shifts second-order tensors from A to B or B to A.

Parameters
[in]A3 x 3 second-order tensor.
[in]eulerEuler angles.
[in]seqES_XYZ | ES_XZY | ES_YXZ | ES_YZX | ES_ZXY | ES_ZYX.
Sequence for Euler angles.
[in]worldWhether the Euler angles are with respect to the world frame or not.
[in]forwardWhether to shift forward, i.e., along the orientation or shift reverse.
[out]Ashift3 x 3 shifted second-order tensor.

◆ euler_shift_tensor3()

void euler_shift_tensor3 ( const double * A,
const double euler[3],
enum EulangSeq seq,
const bool world,
const bool forward,
double * Ashift )

Given two frames A and B such that the orientation of frame B with respect to frame A is given by three Euler angles, shifts third-order tensors from A to B or B to A.

Parameters
[in]A3 x 3 x 3 third-order tensor.
[in]eulerEuler angles.
[in]seqES_XYZ | ES_XZY | ES_YXZ | ES_YZX | ES_ZXY | ES_ZYX.
Sequence for Euler angles.
[in]worldWhether the Euler angles are with respect to the world frame or not.
[in]forwardWhether to shift forward, i.e., along the orientation or shift reverse.
[out]Ashift3 x 3 x 3 shifted third-order tensor.

◆ euler_shift_vectors()

void euler_shift_vectors ( const int n,
const double * v,
const double euler[3],
enum EulangSeq seq,
const bool world,
const bool forward,
double * vshift )

Given two frames A and B such that the orientation of frame B with respect to frame A is given by three Euler angles, shifts vectors from A to B or B to A.

Parameters
[in]nNumber of rows of v.
[in]vn x 3 array whose rows are the vectors to shift.
[in]eulerEuler angles.
[in]seqES_XYZ | ES_XZY | ES_YXZ | ES_YZX | ES_ZXY | ES_ZYX.
Sequence for Euler angles.
[in]worldWhether the Euler angles are with respect to the world frame or not.
[in]forwardWhether to shift forward, i.e., along the orientation or shift reverse.
[out]vshiftn x 3 array whose rows are the rotated vectors.

◆ euler_shiftmat()

void euler_shiftmat ( const double euler[3],
enum EulangSeq seq,
const bool world,
const bool forward,
double * shiftmat )

Calculates the shifter matrix for a set of Euler angles.

Parameters
[in]eulerEuler angles.
[in]seqES_XYZ | ES_XZY | ES_YXZ | ES_YZX | ES_ZXY | ES_ZYX.
Sequence for Euler angles.
[in]worldWhether the Euler angles are with respect to the world frame or not.
[in]forwardWhether to shift forward, i.e., along the orientation or shift reverse.
[out]shiftmat3 x 3 shifter matrix.

◆ euler_to_aa()

void euler_to_aa ( const double euler[3],
enum EulangSeq seq,
const bool world,
double axis[3],
double * angle )

Convert Euler angles to an axis-angle representation.

Parameters
[in]eulerEuler angles.
[in]seqES_XYZ | ES_XZY | ES_YXZ | ES_YZX | ES_ZXY | ES_ZYX.
Sequence for Euler angles.
[in]worldWhether the Euler angles are with respect to the world frame or not.
[out]axisUnit vector along the axis of rotation.
[out]angleAngle of rotation in radian.

◆ euler_to_dcm()

void euler_to_dcm ( const double euler[3],
enum EulangSeq seq,
const bool world,
double * dcm )

Convert Euler angles to a direction cosine matrix.

Parameters
[in]eulerEuler angles.
[in]seqES_XYZ | ES_XZY | ES_YXZ | ES_YZX | ES_ZXY | ES_ZYX.
Sequence for Euler angles.
[in]worldWhether the Euler angles are with respect to the world frame or not.
[out]dcm3 x 3 direction cosine matrix.

◆ euler_to_euler()

void euler_to_euler ( const double euler[3],
enum EulangSeq seq,
const bool world,
enum EulangSeq to_seq,
const bool to_world,
double to_euler[3] )

Converts Convert one set of Euler angles to another.

Parameters
[in]eulerEuler angles.
[in]seqES_XYZ | ES_XZY | ES_YXZ | ES_YZX | ES_ZXY | ES_ZYX.
Sequence for Euler angles.
[in]worldWhether the Euler angles are with respect to the world frame or not.
[in]to_seqES_XYZ | ES_XZY | ES_YXZ | ES_YZX | ES_ZXY | ES_ZYX.
Convert Euler angles with sequence seq to to_euler with sequence to_seq.
[in]to_worldWhether the converted euler angles are with respect to the world frame or not.
[out]to_eulerConverted Euler angles.

◆ euler_to_quat()

void euler_to_quat ( const double euler[3],
enum EulangSeq seq,
const bool world,
double q[4] )

Convert Euler angles to a unit quaternion.

Parameters
[in]eulerEuler angles.
[in]seqES_XYZ | ES_XZY | ES_YXZ | ES_YZX | ES_ZXY | ES_ZYX.
Sequence for Euler angles.
[in]worldWhether the Euler angles are with respect to the world frame or not.
[out]qA unit quaternion.