Next: Retrieving classification information.
Up: Classifying Transformations
Previous: Inserting classification information.
* Declare variables.
INCLUDE 'TRN_PAR'
LOGICAL CLASS( TRN__MXCLS ) [1]
* Create a (temporary) transformation.
CALL TRN_NEW( NVIN, NVOUT, FOR, INV, PREC, [2]
: ' ', ' ', LOCTR, STATUS )
* Set up the logical classification array.
DO 1 I = 1, TRN__MXCLS [3]
CLASS( I ) = .FALSE.
1 CONTINUE
CLASS( TRN__LIN ) = .TRUE. [4]
CLASS( TRN__DIAG ) = .TRUE.
CLASS( TRN__ISOT ) = .TRUE.
CLASS( TRN__POSDT ) = .TRUE.
* Enter the classification information.
CALL TRN_PTCL( CLASS, LOCTR, STATUS ) [5]
Programming notes:
- A 1-dimensional logical array CLASS is declared with
TRN__MXCLS elements (this symbolic constant specifies the number
of basic classification properties currently recognised and is defined in
the include file TRN_PAR).
- A transformation is created.
At this point it does not contain any classification information.
- All elements of the CLASS array are explicitly initialised
to .FALSE. - this precaution is recommended so that the number of
basic classification properties may be increased in future without adversely
affecting existing software.
- The required array elements are set to .TRUE. - in this
example the classification describes a simple linear magnification about a
point with a positive magnification factor (see Table
in Appendix
).
Symbolic constants (also defined in the include file TRN_PAR) are
used to identify the array elements concerned.
- The classification information is entered into the transformation by
calling TRN_PTCL.
Next: Retrieving classification information.
Up: Classifying Transformations
Previous: Inserting classification information.
TRANSFORM Coordinate Transformation Facility
Starlink User Note 61
R.F. Warren-Smith
12th January 2006
E-mail:ussc@star.rl.ac.uk
Copyright © 2000 Council for the Central Laboratory of the Research Councils