Next: Angular format specifiers
Up: Features of the library
Previous: Inquiring null values
Storing and representing columns of angles
CAT provides special facilities for representing columns which
contain angles. Usually angular columns are used to store celestial
coordinates such as Right Ascension and Declination, though they can
contain any angular measure. There are two requirements for the treatment
of angles stored in astronomical catalogues:
- inside a program angles should be expressed in radians
and stored in DOUBLE PRECISION or REAL variables for ease of
processing,
- usually they are best displayed to a user in units of hours
or degrees, subdivided into sexagesimal minutes and seconds.
Alternatively, small angles might be best displayed as minutes or
seconds of arc or time and represented to some number of places of
decimals.
CAT provides both these facilities, as follows:
- when the value of a field in an angular column is
obtained using CAT_EGT0D or CAT_EGT0R it is
returned as DOUBLE PRECISION or REAL variable in radians,
- when the value of a field in an angular column is
obtained formatted for display using CAT_EGT0F it is
returned as a CHARACTER string containing the value expressed in
hours, degrees, minutes or seconds and optionally formatted as a
sexagesimal value.
In order for CAT to know that a column contains an angle it must
satisfy the following two requirements.
If the external display format attribute of the column, EXFMT,
is explicitly set it should be set to a normal Fortran 77 format
specifier corresponding to the data type of the column, for
example `D16.8' for a DOUBLE PRECISION column or `E14.6'
for a REAL column17.
When the catalogue is written fields should be written to
angular columns using CAT_PUT0D or CAT_PUT0R with
the angles expressed in radians.
Subsections
Next: Angular format specifiers
Up: Features of the library
Previous: Inquiring null values
CAT [1ex
Starlink User Note 181
A.C. Davenhall
4th April 2001
E-mail:ussc@star.rl.ac.uk
Copyright © 2001 Council for the Central Laboratory of the Research Councils