# Quaternions and rotations in $\Bbb R^3$

I'm having some trouble understanding the following example in Armstrong's Groups and Symmetry:

''An element of $\mathbb{H}$ of the form $bi + cj + dk$ is called a ''pure quaternion'. Identify the set of all pure quaternions with $\mathbb{R}^3$ via the correspondence $bi + cj + dk \rightarrow (b,c,d).$ If $q$ is a non-zero quaternion, conjugation by $q$ sends the pure quaternions to themselves and induces a rotation of $\mathbb{R}^3$. This construction provides a homomorphism from $\mathbb{H} \smallsetminus\{0\}$ to $SO_3$. Its image is all of $SO_3$, its kernel is $\mathbb{R} \smallsetminus\{0\}$ and therefore $\bigl(\mathbb{H} \smallsetminus\{0\}\bigr) /\bigl(\mathbb{R} \smallsetminus\{0\}\bigr)$ is isomorphic to $SO_3$''.

So suppose that $v$ is a pure quaternion. How exactly does $qvq^{-1}$ induce a rotation of $\mathbb{R}^3$?

-

Quaternions don't really capture the full structure of 3d space, but one can abuse the mathematical properties of it to hack the system and get a solution.

Geometric algebra is a system that subsumes quaternions in a straightforward way. To do this, it uses a "geometric product" of basis vectors, which is written by juxtaposition:

Under the geometric product:

$$e_i e_j = \begin{cases} 1, & i = j \\ -e_j e_i, & i \neq j\end{cases}$$

The geometric product is associative, and this allows one to build chains of such products in an unambiguous way. For example, $e_1 e_2 e_1 e_3 e_1 = -e_2 e_3 e_1$ (just switch the first $e_1$ with $e_2$ at the cost of a minus sign).

How does this connect with rotations and quaternions? Bear with me. We can use the geometric product to build linear operators. One such linear operator is the reflection:

$$\underline N(v) = -e_1 v {e_1}^{-1}$$

The effect of this linear operator is to take the $e_1$ component of any vector and negate it. This is a reflection.

Chaining two separate reflections together allows us to build up a rotation. This is because while a single reflection is not orientation preserving (it has determinant $-1$), two of them put together will have determinant $+1$. Let's consider another reflection that changes the $(e_1+e_2)/\sqrt{2}$ component. The result is

$$\underline R(v) = \frac{e_1 + e_2}{\sqrt{2}} e_1 v e_1 \frac{e_1 + e_2}{\sqrt{2}} = \frac{1}{2}(1 + e_1 e_2) v (1 - e_1 e_2)$$

This describes a particular rotation. The quantity $(1 + e_1 e_2)/\sqrt{2}$ is called a spinor or rotor, and $(1-e_1 e_2)/\sqrt{2}$ is its multiplicative inverse.

In general, though, a spinor or rotor can take the following form:

$$q = a + b e_1 e_2 + c e_2 e_3 + d e_3 e_1$$

which allows us to write any general rotation as

$$\underline R(v) = q v q^{-1}$$

This is the basic idea of quaternions, but instead of an abstract mathematical field, we have derived the form of rotations geometrically, built from reflections. The rotors themselves are linear combinations of scalars and "bivectors", which represent oriented planes in 3d space.

Now, why does using a "pure" quaternion for $v$ give us rotations of vectors? Well, the rotation operator I have described works for pure bivectors (which correspond to pure quaternions), so we can set $a=0$ for $v$ and carry out the proper multiplications. The result will then be

$$\underline R(v) = \underline R(b e_1 e_2 + c e_2 e_3 + d e_3 e_1) = f e_1 e_2 + g e_2 e_3 + h e_3 e_1$$

for some numbers $f, g, h$. One then converts this back to a vector through duality, multiplying on the left or right by $e_1 e_2 e_3$, which we call $i$. The result is

$$(e_1 e_2 e_3) (f e_1 e_2 + g e_2 e_3 + h e_3 e_1) = f e_3 + g e_1 + h e_2$$

This converts the result back to a vector. But the nice thing about geometric algebra is that you don't have to do this hijinks of going back and forth between vectors and bivectors. The rotation operator actually works on vectors--and moreover, this entire approach to rotations works in dimensions other than 3! This generalizes how we use complex exponentials in 2d, and you can use it in 4d to describe rotations, too. This is why I consider the GA approach to be far superior to quaternions, and far easier to connect the concepts to geometric interpretations.

-
Interesting. So in the exterior algebra of $\mathbb{R}^n$, we have $e_i \wedge e_i = 0$, by definition. But here, you're defining that $e_i e_i = 1$. What is the resulting algebra of $\mathbb{R}^n$ called? – goblin Sep 25 at 7:55
The general term is Clifford algebra. I mentioned "geometric algebra", which is a Clifford algebra over a real vector space. In practice, the people who came up with the notion of geometric algebra have their own little community aside from mainstream Clifford algebraists, using their own notation for algebra and analysis (deliberately similar to that of common vector algebra and calculus). The math is not different, however, aside from the simplicity of a real vector space. – Muphrid Sep 25 at 12:42

You're not supposing some particular pure quaternion $v$. Instead, fix some nonzero quaternion $q$ and consider the map $f:\mathbb R^3\to\mathbb R^3$ given by $$f(v) = \alpha(q\alpha^{-1}(v)q^{-1})$$ where $\alpha$ is the correspondence $bi + cj + dk \mapsto (b,c,d)$.

The book then claims that $f$ is a rotation. This really consists of two subclaims:

1. $f$ is well-defined, which requires that $q\alpha^{-1}(v)q^{-1}$ is always in the domain of $\alpha$ -- i.e., that $qxq^{-1}$ is a pure quaternion whenever $x$ is.

2. The function $f:\mathbb R^3\to \mathbb R^3$ happens to be a rotation.

Proving these two subclaims seems to be a "hidden exercise". Since everything is quite clearly linear in $v$, as well as symmetric in the three imaginary directions, it suffices to prove for an arbitrary $q$ that

1. $qiq^{-1}$ is a pure quaternion.
2. $qiq^{-1}$ has length 1.
3. $qiq^{-1}$ and $qjq^{-1}$ are orthogonal.
4. The matrix for $f$ has determinant 1. (From 2 and 3 you know that it must be $\pm 1$; it is also clearly a continuous function of $q$, and since the determinant is $1$ for $q=1$, it must be $1$ everywhere since $\mathbb H\setminus\{0\}$ is path connected).

It may help first to prove that $qvq^{-1}=pvp^{-1}$ if $p$ and $q$ are real multiples of each other, and thus without loss of generality you can assume $\|q\|=1$ and so $q^{-1}=q^*$.

-
The book also claims that any rotation is generated in this way, which is harder to prove it seems. – Peter Nov 25 '12 at 15:33
@Peter: Yes, unless one already knows a simple family of generators of SO(3). But if we do, all that is needed is to display some particular quaternions that map to them, such as $\cos\frac\theta2+i\sin\frac\theta2$ and $\cos\frac\theta2+j\sin\frac\theta2$. – Henning Makholm Nov 25 '12 at 16:05
The book does not mention generators of $SO_3$ in the chapters preceeding this part. The group $SO_3$ is simply introduced as the subgroup of $GL_n(\mathbb{R})$ consisting of the orthogonal matrices with determinant +1. Yet it tells the reader to check that the construction is a surjective homomorphism. However, I don't see any way to check this without finding a set of generators first. – Peter Nov 25 '12 at 16:16

You can just explicitely calculate $qvq^{-1}$ for a given $q=w+xi+yj+zk$, read the matrix of the transformation of the coordinates $b$, $c$, $d$ and check that it has determinant 1 and determine its kernel by direct calculation.

-

The map $v\rightarrow qvq^{-1}$ is a rotation of $R^3$, viewed as the set of pure quaternions.

-