Added some (lightly tested) quaternion utility functions