Md. Shuster et Ga. Natanson, QUATERNION COMPUTATION FROM A GEOMETRIC POINT-OF-VIEW, The Journal of the astronautical sciences, 41(4), 1993, pp. 545-556
Global algorithms that solve for the quaternion generally have a four-
fold multiplicity in order to avoid singularities. A geometrically-mot
ivated construction is presented that automatically generates the four
-fold multiplicity of algorithms once a single (possibly singular) alg
orithm is known. As examples of the application of this procedure, lea
st-squares attitude determination and the computation of the quaternio
n from the direction-cosine matrix are examined. In the latter applica
tion, the method proposed here leads to Shepperd's algorithm for extra
cting the quaternion from the rotation matrix.