IRFTRN ( Inertial reference frame transformation )
SUBROUTINE IRFTRN ( REFA, REFB, ROTAB )
Return the matrix that transforms vectors from one specified
inertial reference frame to another.
DOUBLE PRECISION ROTAB ( 3, 3 )
Variable I/O Description
-------- --- --------------------------------------------------
REFA I Name of reference frame to transform vectors FROM.
REFB I Name of reference frame to transform vectors TO.
ROTAB O REFA-to-REFB transformation matrix.
REFB Names of two inertial reference frames. Any names
accepted by the routine IRFNUM may be used. See
$Particulars for a list of some of the more
commonly used inertial reference frame names.
ROTAB is a rotation matrix that transforms the
coordinates of a vector V relative to the
reference frame specified by REFA to the
coordinates of V relative to the reference frame
specified by REFB. The transformation is carried
out by the matrix multiplication
V = ROTAB * V.
1) If either of the input reference frame names is invalid, the
error will be diagnosed by routines called by this routine.
Normally applications should call the more general, higher level
routine PXFORM instead of this routine.
This routine is a macro that replaces the code fragment
CALL IRFNUM ( REFA, CODEA )
CALL IRFNUM ( REFB, CODEB )
CALL IRFROT ( CODEA, CODEB, ROTAB )
Among the reference frame names accepted by IRFNUM are:
See the SPICELIB routine GHGIRF for details.
1) Transform a vector V1950 from the B1950 to the J2000
C Ask IRFTRN for the matrix that transforms vectors
C from the B1950 to the J2000 reference frame.
CALL IRFTRN ( 'B1950', 'J2000', TRANS )
C Now transform V1950 to the J2000 reference frame.
CALL MXV ( TRANS, V1950, V2000 )
N.J. Bachman (JPL)
SPICELIB Version 1.0.2, 28-SEP-2004 (NJB)
Corrected comment in code example in header. Made other minor
updates to header.
SPICELIB Version 1.0.1, 10-MAR-1992 (WLT)
Comment section for permuted index source lines was added
following the header.
SPICELIB Version 1.0.0, 30-AUG-1991 (NJB)