info prev up next book cdrom email home

Euler Angles

\begin{figure}\begin{center}\BoxedEPSF{EulerAngles.epsf scaled 600}\end{center}\end{figure}

According to Euler's Rotation Theorem, any Rotation may be described using three Angles. If the Rotations are written in terms of Rotation Matrices B, C, and D, then a general Rotation A can be written as

\begin{displaymath}
{\hbox{\sf A}}={\hbox{\sf B}}{\hbox{\sf C}}{\hbox{\sf D}}.
\end{displaymath} (1)

The three angles giving the three rotation matrices are called Euler angles. There are several conventions for Euler angles, depending on the axes about which the rotations are carried out. Write the Matrix A as
\begin{displaymath}
{\hbox{\sf A}}\equiv \left[{\matrix{
a_{11} & a_{12} & a_{13...
...21} & a_{22} & a_{23}\cr
a_{31} & a_{32} & a_{33}\cr}}\right].
\end{displaymath} (2)


In the so-called ``$x$-convention,'' illustrated above,

$\displaystyle {\hbox{\sf D}}$ $\textstyle \equiv$ $\displaystyle \left[\begin{array}{ccc}\cos\phi & \sin\phi & 0\\  -\sin\phi & \cos\phi & 0\\  0 & 0 & 1\end{array}\right]$ (3)
$\displaystyle {\hbox{\sf C}}$ $\textstyle \equiv$ $\displaystyle \left[\begin{array}{ccc}1 & 0 & 0\\  0 & \cos\theta & \sin\theta\\  0 & -\sin\theta & \cos\theta\end{array}\right]$ (4)
$\displaystyle {\hbox{\sf B}}$ $\textstyle \equiv$ $\displaystyle \left[\begin{array}{ccc}\cos\psi & \sin\psi & 0\\  -\sin\psi & \cos\psi & 0\\  0 & 0 & 1\end{array}\right],$ (5)

so
$\displaystyle a_{11}$ $\textstyle =$ $\displaystyle \cos\psi\cos\phi-\cos\theta\sin\phi\sin\psi$  
$\displaystyle a_{12}$ $\textstyle =$ $\displaystyle \cos\psi\sin\phi+\cos\theta\cos\phi\sin\psi$  
$\displaystyle a_{13}$ $\textstyle =$ $\displaystyle \sin\psi\sin\theta$  
$\displaystyle a_{21}$ $\textstyle =$ $\displaystyle -\sin\psi\cos\phi-\cos\theta\sin\phi\cos\psi$  
$\displaystyle a_{22}$ $\textstyle =$ $\displaystyle -\sin\psi\sin\phi+\cos\theta\cos\phi\cos\psi$  
$\displaystyle a_{23}$ $\textstyle =$ $\displaystyle \cos\psi\sin\theta$  
$\displaystyle a_{31}$ $\textstyle =$ $\displaystyle \sin\theta\sin\phi$  
$\displaystyle a_{32}$ $\textstyle =$ $\displaystyle -\sin\theta\cos\phi$  
$\displaystyle a_{33}$ $\textstyle =$ $\displaystyle \cos\theta$  

To obtain the components of the Angular Velocity $\boldsymbol{\omega}$ in the body axes, note that for a Matrix
\begin{displaymath}
{\hbox{\sf A}}\equiv \left[{\matrix{{\bf A}_1 & {\bf A}_2 & {\bf A}_3\cr}}\right],
\end{displaymath} (6)

it is true that
$\displaystyle \left[\begin{array}{ccc} a_{11} & a_{12} & a_{13} \\  a_{21} & a_...
...right] \left[\begin{array}{c}\omega_x\\  \omega_y\\  \omega_z\end{array}\right]$ $\textstyle =$ $\displaystyle \left[\begin{array}{c} a_{11}\omega_x+a_{12}\omega_y+a_{13}\omega...
...ga_z\\  a_{31}\omega_x+a_{32}\omega_y+a_{33}\omega_z\end{array}\right]\nonumber$  
      (7)
  $\textstyle =$ $\displaystyle {\bf A}_1\omega_x+{\bf A}_2\omega_y+{\bf A}_3\omega_z.$ (8)

Now, $\omega_z$ corresponds to rotation about the $\phi$ axis, so look at the $\omega_z$ component of ${\hbox{\sf A}}\boldsymbol{\omega}$,
\begin{displaymath}
\boldsymbol{\omega}_\phi = {\bf A}_1\omega_z = \left[{\matri...
...theta\cr \cos\psi\sin\theta\cr\cos \theta\cr}}\right]\dot\phi.
\end{displaymath} (9)

The line of nodes corresponds to a rotation by $\theta$ about the $\xi$-axis, so look at the $\omega_\xi$ component of ${\hbox{\sf B}}\boldsymbol{\omega}$,
\begin{displaymath}
\boldsymbol{\omega}_\theta = {\bf B}_1\omega_\xi = {\bf B}_1...
...eft[{\matrix{\cos\psi\cr -\sin\psi\cr 0\cr}}\right]\dot\theta.
\end{displaymath} (10)

Similarly, to find rotation by $\psi$ about the remaining axis, look at the $\omega_\psi$ component of ${\hbox{\sf B}}\boldsymbol{\omega}$,
\begin{displaymath}
\boldsymbol{\omega}_\psi={\bf B}_3\omega_\psi = {\bf B}_3\dot\psi = \left[{\matrix{0\cr 0\cr 1\cr}}\right]\dot\psi.
\end{displaymath} (11)

Combining the pieces gives
\begin{displaymath}
\boldsymbol{\omega}=\left[{\matrix{\sin\psi\sin\theta \dot\p...
...dot\phi-\sin\psi\cr
\cos\theta \dot\phi+\dot\psi.\cr}}\right]
\end{displaymath} (12)

For more details, see Goldstein (1980, p. 176) and Landau and Lifschitz (1976, p. 111).


The $x$-convention Euler angles are given in terms of the Cayley-Klein Parameters by


$\displaystyle \phi$ $\textstyle =$ $\displaystyle -2i\ln\left[{\pm {\alpha^{1/2}\gamma^{1/4}\over\beta^{1/4}(1+\bet...
...t[{\pm {i\alpha^{1/2}\gamma^{1/4}\over\beta^{1/4}(1+\beta\gamma)^{1/4}}}\right]$ (13)
$\displaystyle \psi$ $\textstyle =$ $\displaystyle -2i\ln\left[{\pm {\alpha^{1/2}\beta^{1/4}\over\gamma^{1/4}(1+\bet...
...t[{\pm {i\alpha^{1/2}\beta^{1/4}\over\gamma^{1/4}(1+\beta\gamma)^{1/4}}}\right]$ (14)
$\displaystyle \theta$ $\textstyle =$ $\displaystyle \pm 2\cos^{-1}(\pm\sqrt{1+\beta\gamma}\,).$ (15)


In the ``$y$-convention,''

\begin{displaymath}
\phi_x \equiv \phi_y + {\textstyle{1\over 2}}\pi
\end{displaymath} (16)


\begin{displaymath}
\psi_x \equiv \psi_y - {\textstyle{1\over 2}}\pi.
\end{displaymath} (17)

Therefore,
\begin{displaymath}
\sin\phi_x = \cos\phi_y
\end{displaymath} (18)


\begin{displaymath}
\cos\phi_x = -\sin\phi_y
\end{displaymath} (19)


\begin{displaymath}
\sin\psi_x = -\cos\psi_y
\end{displaymath} (20)


\begin{displaymath}
\cos\psi_x = \sin\psi_y
\end{displaymath} (21)


$\displaystyle {\hbox{\sf D}}$ $\textstyle \equiv$ $\displaystyle \left[\begin{array}{ccc}-\sin\phi & \cos\phi & 0\\  -\cos\phi & -\sin\phi & 0\\  0 & 0 & 1\end{array}\right]$ (22)
$\displaystyle {\hbox{\sf C}}$ $\textstyle \equiv$ $\displaystyle \left[\begin{array}{ccc}1 & 0 & 0\\  0 & \cos\theta & \sin\theta\\  0 & -\sin\theta & \cos\theta\end{array}\right]$ (23)
$\displaystyle {\hbox{\sf B}}$ $\textstyle \equiv$ $\displaystyle \left[\begin{array}{ccc}\sin\psi & -\cos\psi & 0\\  \cos\psi & \sin\psi & 0\\  0 & 0 & 1\end{array}\right]$ (24)

and A is given by
$\displaystyle a_{11}$ $\textstyle =$ $\displaystyle -\sin\psi\sin\phi+\cos\theta\cos\phi\cos\psi$  
$\displaystyle a_{12}$ $\textstyle =$ $\displaystyle \sin\psi\cos\phi+\cos\theta\sin\phi\cos\psi$  
$\displaystyle a_{13}$ $\textstyle =$ $\displaystyle -\cos\psi\sin\theta$  
$\displaystyle a_{21}$ $\textstyle =$ $\displaystyle -\cos\psi\sin\phi-\cos\theta\cos\phi\sin\psi$  
$\displaystyle a_{22}$ $\textstyle =$ $\displaystyle \cos\psi\cos\phi-\cos\theta\sin\phi\sin\psi$  
$\displaystyle a_{23}$ $\textstyle =$ $\displaystyle \sin\psi\sin\theta$  
$\displaystyle a_{31}$ $\textstyle =$ $\displaystyle \sin\theta\cos\phi$  
$\displaystyle a_{32}$ $\textstyle =$ $\displaystyle \sin\theta\sin\phi$  
$\displaystyle a_{33}$ $\textstyle =$ $\displaystyle \cos\theta.$  


In the ``$xyz$'' (pitch-roll-yaw) convention, $\theta$ is pitch, $\psi$ is roll, and $\phi$ is yaw.

$\displaystyle {\hbox{\sf D}}$ $\textstyle \equiv$ $\displaystyle \left[\begin{array}{ccc}\cos\phi & \sin\phi & 0\\  -\sin\phi & \cos\phi & 0\\  0 & 0 & 1\end{array}\right]$ (25)
$\displaystyle {\hbox{\sf C}}$ $\textstyle \equiv$ $\displaystyle \left[\begin{array}{ccc}\cos\theta & 0 & -\sin\theta\\  0 & 1 & 0\\
\sin\theta & 0 & \cos\theta\end{array}\right]$  
$\displaystyle {\hbox{\sf B}}$ $\textstyle \equiv$ $\displaystyle \left[\begin{array}{ccc}1 & 0 & 0\\  0 & \cos\psi & \sin\psi\\  0 & -\sin\psi & \cos\psi\end{array}\right]$ (26)

and A is given by
$\displaystyle a_{11}$ $\textstyle =$ $\displaystyle \cos\theta\cos\phi$  
$\displaystyle a_{12}$ $\textstyle =$ $\displaystyle \cos\theta\sin\phi$  
$\displaystyle a_{13}$ $\textstyle =$ $\displaystyle -\sin\theta$  
$\displaystyle a_{21}$ $\textstyle =$ $\displaystyle \sin\psi\sin\theta\cos\phi-\cos\psi\sin\phi$  
$\displaystyle a_{22}$ $\textstyle =$ $\displaystyle \sin\psi\sin\theta\sin\phi+\cos\psi\cos\phi$  
$\displaystyle a_{23}$ $\textstyle =$ $\displaystyle \cos\theta\sin\psi$  
$\displaystyle a_{31}$ $\textstyle =$ $\displaystyle \cos\psi\sin\theta\cos\phi+\sin\psi\sin\phi$  
$\displaystyle a_{32}$ $\textstyle =$ $\displaystyle \cos\psi\sin\theta\sin\phi-\sin\psi\cos\phi$  
$\displaystyle a_{33}$ $\textstyle =$ $\displaystyle \cos\theta\cos\psi.$  


A set of parameters sometimes used instead of angles are the Euler Parameters $e_0$, $e_1$, $e_2$ and $e_3$, defined by

$\displaystyle e_0$ $\textstyle \equiv$ $\displaystyle \cos\left({\phi\over 2}\right)$ (27)
$\displaystyle {\bf e}$ $\textstyle \equiv$ $\displaystyle \left[\begin{array}{c}e_1\\  e_2\\  e_3\end{array}\right] = \hat {\bf n} \sin\left({\phi\over 2}\right).$ (28)

Using Euler Parameters (which are Quaternions), an arbitrary Rotation Matrix can be described by
$\displaystyle a_{11}$ $\textstyle =$ $\displaystyle {e_0}^2+{e_1}^2-{e_2}^2-{e_3}^2$  
$\displaystyle a_{12}$ $\textstyle =$ $\displaystyle 2(e_1e_2+e_0e_3)$  
$\displaystyle a_{13}$ $\textstyle =$ $\displaystyle 2(e_1e_3-e_0e_2)$  
$\displaystyle a_{21}$ $\textstyle =$ $\displaystyle 2(e_1e_2-e_0e_3)$  
$\displaystyle a_{22}$ $\textstyle =$ $\displaystyle {e_0}^2-{e_1}^2+{e_2}^2-{e_3}^2$  
$\displaystyle a_{23}$ $\textstyle =$ $\displaystyle 2(e_2e_3+e_0e_1)$  
$\displaystyle a_{31}$ $\textstyle =$ $\displaystyle 2(e_1e_3+e_0e_2)$  
$\displaystyle a_{32}$ $\textstyle =$ $\displaystyle 2(e_2e_3-e_0e_1)$  
$\displaystyle a_{33}$ $\textstyle =$ $\displaystyle {e_0}^2-{e_1}^2-{e_2}^2+{e_3}^2$  

(Goldstein 1960, p. 153).


If the coordinates of two pairs of $n$ points ${\bf x}_i$ and ${\bf x}'_i$ are known, one rotated with respect to the other, then the Euler rotation matrix can be obtained in a straightforward manner using Least Squares Fitting. Write the points as arrays of vectors, so

\begin{displaymath}
\left[{\matrix{{\bf x}_1' & \cdots & {\bf x}_n'\cr}}\right] ...
... A}}\left[{\matrix{{\bf x}_1 & \cdots & {\bf x}_n\cr}}\right].
\end{displaymath} (29)

Writing the arrays of vectors as matrices gives
\begin{displaymath}
{\hbox{\sf X}}'={\hbox{\sf A}}{\hbox{\sf X}}
\end{displaymath} (30)


\begin{displaymath}
{\hbox{\sf X}}'{\hbox{\sf X}}^{\rm T}={\hbox{\sf A}}{\hbox{\sf X}}{\hbox{\sf X}}^{\rm T},
\end{displaymath} (31)

and solving for ${\hbox{\sf A}}$ gives
\begin{displaymath}
{\hbox{\sf A}}={\hbox{\sf X}}'{\hbox{\sf X}}^{\rm T}({\hbox{\sf X}}{\hbox{\sf X}}^{\rm T})^{-1}.
\end{displaymath} (32)

However, we want the angles $\theta$, $\phi$, and $\psi$, not their combinations contained in the Matrix ${\hbox{\sf A}}$. Therefore, write the $3\times 3$ Matrix
\begin{displaymath}
{\hbox{\sf A}}=\left[{\matrix{
f_1(\theta,\phi,\psi) & f_2(\...
...i) & f_7(\theta,\phi,\psi) & f_9(\theta,\phi,\psi)\cr}}\right]
\end{displaymath} (33)

as a $1\times 9$ Vector
\begin{displaymath}
{\bf f}=\left[{\matrix{f_1(\theta,\phi,\psi)\cr \vdots\cr f_9(\theta,\phi,\psi)\cr}}\right].
\end{displaymath} (34)

Now set up the matrices


\begin{displaymath}
\left[{\matrix{
\left.{\partial f_1\over\partial\theta}\righ...
...\left[{\matrix{d\theta\cr d\phi\cr d\psi\cr}}\right]=d{\bf f}.
\end{displaymath} (35)

Using Nonlinear Least Squares Fitting then gives solutions which converge to $(\theta, \phi, \psi)$.

See also Cayley-Klein Parameters, Euler Parameters, Euler's Rotation Theorem, Infinitesimal Rotation, Quaternion, Rotation, Rotation Matrix


References

Arfken, G. Mathematical Methods for Physicists, 3rd ed. Orlando, FL: Academic Press, pp. 198-200, 1985.

Goldstein, H. ``The Euler Angles'' and ``Euler Angles in Alternate Conventions.'' §4-4 and Appendix B in Classical Mechanics, 2nd ed. Reading, MA: Addison-Wesley, pp. 143-148 and 606-610, 1980.

Landau, L. D. and Lifschitz, E. M. Mechanics, 3rd ed. Oxford, England: Pergamon Press, 1976.



info prev up next book cdrom email home

© 1996-9 Eric W. Weisstein
1999-05-25