'w' is now obtained from 'v' using the relation w = sqrt(1 - |sqr(v)|)
and 'v' is stored in the joint state field 'q' and integrated in the
usual manner but corrected using quaternion transformations.
This is a more convenient way of maintaining the state or multiple
states (for higher-order integration), storing, retrieving and passing
between processors.