When switching to the double covered quaternion pair, the corresponding distance was not computed correctly