Euler angles is a way of describing the rotation in 3D space using three separate rotations around an axes.
Euler angles are usually defined one of the two symbol sets:
\( \alpha, \beta, \gamma \)(Alpha, Beta, Gamma). These are usually used with proper Euler angles (see below).
\( \Phi, \Theta, \Psi \)(Phi, Theta, Psi). These are usually used with Tait-Bryan angles (see below).
Proper Euler Angles vs. Tait-Bryan Angles
Euler angles can be split into two categories based on the axis used:
- Proper Euler Angles: These use the same axis for both the first and third rotations, e.g. x-y-x, x-z-x, y-x-y, y-z-y, z-x-z, z-y-z
- Tait-Bryan Angles: These use all three axis (no axis is used twice), e.g. x-y-z, x-z-y, y-x-z, y-z-x, z-x-y, z-y-x
Proper Euler angles are also called classic Euler angles.
The classic roll, pitch, yaw (RPY) terminology is a Tait-Bryan angle. Tait-Bryan angles are also called Cardan angles, nautical angles, or heading, elevation and bank.
The axes of the initial frame (also called the reference frame) is denoted with x, y, z. The rotated frame is denoted with X, Y, Z.
The line of nodes is the line (or vector) made by the intersection of the xy and XY planes.
Calculating Euler Angles Between Two 3D Vectors
First we calculate the cross-product of the two vectors, which gives us the vector of rotation:
If you are using unit vectors, you can ignore the lengths (this would just divide by 1).
Conversion To Rotation Matrices
Euler angles can be converted to rotation matrices.
We can combine these to form a single rotation matrix:
Once the rotation matrix has been calculated, you can rotate any point/vector in the original reference frame to the rotated frame with the equation:
Conversion From Rotation Matrices
\( atan2(y, x) \) returns the principle angle.
- gimbal lock