Optimization over SO(3)
Gradients and Hessians needed to optimize over the space of rotations,
parametrized using the tangent space to SO(3)/the exponential map.
See doc/OptimizingRotations.pdf for more explanation and the derivations.
This code provides the gradients and Hessians for rotation matrices and rotated
vectors/matrices with respect to the variables parametrizing the rotation.