Euler-Rodrigues formula (source code)

= Euler-Rodrigues formula
{c}

= Euler-Rodrigues quaternion formula
{c}
{synonym}

For a unit <quaternion> $q=(w,v)$ with $v\in\mathbb R^3$, the <Euler-Rodrigues formula> gives the rotation
$$
R=(w^2-v\cdot v)I+2vv^T+2w[v]_\times,
$$
where $[v]_\times x=v\times x$. It follows by expanding quaternion conjugation $x\mapsto qxq^{-1}$ for a purely imaginary <quaternion> $x$.

Writing $w=\cos(\theta/2)$ and $v=n\sin(\theta/2)$ gives rotation through angle $\theta$ about the unit axis $n$. Both $q$ and $-q$ give the same <rotation matrix>, displaying the double cover by <unit quaternions>. The formula is useful for combining spatial rotations without singular angle coordinates.