RCNVRT converts rotational coordinates from one representation to another.
Use
Called By
Any user-written subroutine
Prerequisite
None
Calling Sequence
CALL RCNVRT (sys1, coord1, sys2, coord2, istat)
Input Arguments
sys1 | A character string specifying the system in which the values passed in coord1 were determined. The following table shows the possible character strings and their meanings:  |
| |
sys2 | A character string specifying the system in which the values returned as output in coord2 are to be determined. Possible character strings are the same as those for sys1. |
coord1 | A double-precision array containing the coordinates to be converted. Angles should be input in radians. |
Output Arguments
coord2 | An array containing the converted coordinates. Angles are output in radians. |
istat | An integer variable indicating the unqualified success, the qualified success, or the reason for the failure of the call to RCNVRT. The values for istat are as follows:  |
Extended Definition
In Adams Solver, rotational coordinates are often used to specify the orientation of a coordinate system. For example, a DIFSUB, a REQSUB, or an SFOSUB can call RCNVRT to change Euler angles to Euler parameters.
Euler parameters are P0, P1, P2, and P3. P0 is the cosine of one-half the angle of rotation of the rotated frame with respect to the reference frame. P1, P2, and P3 are the x, y, and z components, respectively, of the unit vector around which the rotation occurs, multiplied by the sine of one-half the angle.
Rodrigues parameters (R1, R2, and R3) define the relative rotation between two frames of reference. The relationship between Rodrigues parameters and Euler parameters is R1 = P1/P0, R2 = P2/P0, and R3 = P3/P0. Rodrigues parameters become undefined when P0 = 0, that is, when the angle of rotation about the vector is 180 degrees.
Tip
The coord1 and coord2 array length is three, except when the coordinates are in the EULPAR system (when the array length is four) or in the COSINES system (when the array length is nine). The nine values of the COSINES system, which forms a three-by-three matrix, are stored in row order in coord2.