next up previous contents
Next: Nearness Measure for HepRotations, Up: HepRotation Class Previous: Axial Rotations   Contents

Expressing a HepRotation as HepAxisAngle or HepEulerAngles

It is worth noting that equations ([*]) and ([*]) are not single-valued when extracting $ ( \hat{u}, \delta) $ or $(\phi, \theta, \psi)$ from a Rotation matrix. We adhere to the following conventions to resolve that ambiguity whenever forming an HepAxisAngle or HepEulerAngles from a Rotation$R$:


$\displaystyle R = {\bf I} \Longrightarrow \delta = 0, \; \hat{u} = \hat{z}$     (142)
$\displaystyle R \longrightarrow ( \hat{u}, \delta ) \Longrightarrow 0 \leq \delta \leq \pi$     (143)
$\displaystyle R \longrightarrow ( \phi, \theta, \psi )
\Longrightarrow 0 \leq \theta \leq \pi$     (144)
$\displaystyle R \longrightarrow ( \phi, \; \theta = 0, \; \psi )
\Longrightarrow -\pi/2 < \phi = \psi \leq \pi/2$     (145)
$\displaystyle R \longrightarrow ( \phi, \; \theta = \pi, \; \psi )
\Longrightarrow -\pi/2 < \phi = -\psi \leq \pi/2$     (146)

Thus when supplying values for Euler angles, we return $(0, 0, 0)$ whenever the rotation is equivalent to the identity, and return $(0, \pi, 0)$ in preference to the equivalent $(\pi, \pi, \pi)$.

In particular, special case rotations such as HepRotationX with $\delta$ supplied as zero or $\pi$ obey these conventions: even though for $\delta = \pi - \vert\epsilon\vert$ a RotationX would have Euler angles $( \pi, \delta, \pi, )$, when $\delta = \pi$ exactly, the Euler angles are $(0, \delta=\pi, 0)$.

These conventions for how methods return values for Euler angles do not affect the user's right to supply explicit values for $ ( \hat{u}, \delta) $ or $(\phi, \theta, \psi)$ when defining one of those structures. Similarly, the conventions for reading axis and angle do not affect the user's ability to supply arbitrary values for the angle $\delta$.

Obeying the above rules, Euler angles returned for rotations about coordinate axes behave as follows:


\begin{displaymath}
\mbox{HepRotationX}(\delta) \longrightarrow
\left\{
\begin{a...
...
( 0, \pi, 0 ) & \mbox{ if } & \delta = \pi
\end{array}\right.
\end{displaymath} (147)


\begin{displaymath}
\mbox{HepRotationY}(\delta) \longrightarrow
\left\{
\begin{a...
...elta, -\pi/2 ) & \mbox{ if } & \delta = \pi
\end{array}\right.
\end{displaymath} (148)


\begin{displaymath}
\mbox{HepRotationZ}(\delta) \longrightarrow ( -\delta/2, 0, -\delta/2 )
\end{displaymath} (149)

always assuming that $\delta$ represents an angle of active rotation between $\-pi$ and $\pi$.


next up previous contents
Next: Nearness Measure for HepRotations, Up: HepRotation Class Previous: Axial Rotations   Contents
Fermilab ZOOM Physics Class Library Task Force