What is the formula for the composition of two axis-angle rotation vectors? Most people only know about representing rotations as matrices, quaternions, or Euler angles.  But there's one other way to represent rotations, known as the axis-angle representation.  This is where you draw a vector, known as the rotation vector, whose magnitude is equal to the angle of the rotation and which points along the axis of the rotation.  
Now because finite rotations do not commute, in general you cannot obtain the composition of two rotations by taking the vector sum of the two rotation vectors.  (This is in contrast to angular velocity vectors, which do add vectorially as you can see in this excerpt from Taylor's Classical Mechanics textbook.)  So my question is, what is the formula for the rotation vector corresponding the composition of two rotation vectors?
Note that I don't want a procedure which involves converting from the axis-angle representation to some other representation (like quarternions or matrices), obtaining the composition through that representation, and then converting back to the axis-angle representation.  I'm talking an explicit formula which gives the rotation vector of the composition as a function of the two rotation vectors.
 A: The formula is given in this excerpt from a journal paper.  It was discovered by the French mathematician Olinde Rodrigues in 1840, which was before the invention of vectors or even quaternions (which were invented before vectors).
The composition of $\alpha\hat{l}$ and $\beta\hat{m}$ (where the second rotation is applied and then the first is applied) is given by $\gamma\hat{n}$, where $\cos\frac{\gamma}{2} = \cos\frac{\alpha}{2}\cos\frac{\beta}{2} - \sin\frac{\alpha}{2}\sin\frac{\beta}{2}\hat{l}\cdot\hat{m}$ and $\sin\frac{\gamma}{2}\hat{n}=\sin\frac{\alpha}{2}\cos\frac{\beta}{2}\hat{l}+\cos\frac{\alpha}{2}\sin\frac{\beta}{2}\hat{m}+\sin\frac{\alpha}{2}\sin\frac{\beta}{2}\hat{l}\times\hat{m}$.
As a sanity check, it's easy to see that when $\hat{l}=\hat{m}$, then $\gamma=\alpha+\beta$ and $\hat{n}= \hat{l}=\hat{m}$.
In any case, these formulas are proven in detail in this chapter of Simon Altman's book "Rotations, Quaternions, and Double Groups", but it basically boils down to this spherical triangle: 

See also this related result proven by William Rowan Hamilton after he invented quaternions.
