Starlink Project
Starlink User Note 61.4

R.F. Warren-Smith

12th January 2006

Copyright © 2000 Council for the Central Laboratory of the Research Councils

TRANSFORM — Coordinate Transformation Facility

Version 0.9-6

Programmer’s Guide and Reference Manual


TRANSFORM provides a standard, flexible method for manipulating coordinate transformations and for transferring information about them between applications. It can handle coordinate systems with any number of dimensions and can efficiently process large (i.e. image-sized) arrays of coordinate data using a variety of numerical precisions. No specific support for astronomical coordinate transformations or map projections is included – these features are provided by the AST library.


1 Introduction
 1.1 What is the TRANSFORM Facility?
2 Basic Concepts and Terminology
 2.1 Transformations
  2.1.1 Transformation variables.
 2.2 Mappings
  2.2.1 Notation
 2.3 Transformation Functions
3 Simple use of TRANSFORM Routines
 3.1 Formulating a Transformation
 3.2 Creating a Transformation
 3.3 Temporary Transformations
 3.4 Compilation
 3.5 Inquiry Routines
 3.6 Transforming 1-Dimensional Coordinate Data
 3.7 Transforming 2-Dimensional Coordinate Data
 3.8 Clearing Up and Closing Down
4 Additional Features
 4.1 Transforming General Coordinate Data
 4.2 Handling of Bad Coordinate Values
 4.3 Concatenating Transformations
  4.3.1 Performing concatenation
 4.4 Prefixing and Appending Transformations
 4.5 Inverting Transformations
 4.6 Formatting Transformation Functions
5 More Advanced Topics
 5.1 Classifying Transformations
 5.2 Arithmetic Precision
6 Compiling and Linking
A Transformation Functions
 A.1 General Form
 A.2 Expression Syntax
 A.3 Built-in Functions
B Classification Properties
 B.1 General
 B.2 Basic Properties
 B.3 Composite Properties
C HDS Structures
 C.1 The TRN_TRANSFORM Structure
 C.2 The TRN_MODULE Structure
 C.3 The TRN_CLASS Structure
D Routine Descriptions
 D.1 Routine List
 D.2 Full Routine Specifications
TRN_ANNUL – Annul compiled mapping
TRN_APND – Append transformation
TRN_CLOSE – Close the TRANSFORM facility
TRN_COMP – Compile transformation
TRN_GTCL – Get classification
TRN_GTCLC – Get compiled classification
TRN_GTNV–Get numbers of variables
TRN_GTNVC–Get numbers of compiled variables
TRN_INV–Invert transformation
TRN_JOIN – Concatenate transformations
TRN_NEW – Create new transformation
TRN_PRFX–Prefix transformation
TRN_PTCL–Put classification
TRN_STOK[x]–Substitute token
TRN_TR1x–Transform 1-dimensional data
TRN_TR2x–Transform 2-dimensional data
TRN_TRNx–Transform general data

E Error Handling
 E.1 The STATUS Argument and Error Reporting
 E.2 Error Codes