STSDAS data files contain information in their headers (usually in the group parameter block) which describes a mapping between pixel coordinates and world coordinates. For example, a spectral dispersion relation can be given, or the mapping between (X,Y) and (a,d) can be specified.
The STSDAS conventions for specifying the world coordinate system are similar to the FITS conventions, but differ in several significant ways. Actually, papers describing the FITS format do not fully define how a WCS is to be specified, but some conventions have come into practical use.
The mapping between pixel coordinates and world coordinates is defined by the keywords described in Table 3.5.
Keywords Defining Mapping Between Pixel and World Coordinates
The keywords CDi_j (CD stands for Coordinate Description) are used instead of the FITS keywords CDELTi and CROTAi because of the ambiguity in the FITS keyword: the sense of the rotation has not been clearly or uniformly defined. CDELTi and CROTAi cannot unambig- uously define a non-orthogonal coordinate system.
CTYPEi is used to define the type of coordinate. In STSDAS data, the values assigned to CTYPEi are typically RA---TAN, DEC--TAN (equatorial coordinates with a tangent plane projection), TIME, CHANNEL, LAMBDA (a wavelength dispersion relation), and PIXEL. The value of CTYPEi defines both a label for the axes and, for sky coordinates, a projection geometry to use in converting (X,Y) to (a,d). The other values of CTYPEi denote linear transformations.
CRPIXi and CRVALi are interrelated. CRVALi is the value of the world coordinate at pixel CRPIXi. For linear world coordinate systems, CRVALi and CRPIXi can both be modified, as long as the changes are self-consistent. In sky projection geometries, however, CRVALi denotes the point of tangency and cannot be changed without resampling the image. When an image section is extracted from an image, the values of CRPIXi are updated to reflect the change in the pixel numbering. CRPIXi may have any value--the reference pixel can lie outside the image (CRPIXi < 0 or CRPIXi > NAXISi) and can have a fractional value.
The CD matrix is defined by the partial derivatives of the world coordinates with respect to the pixel coordinates as evaluated at the reference pixel. For linear coordinate systems this distinction is not significant, but for non-linear systems such as a tangent plane projection the distinction is critical. For example, for a linear wavelength dispersion relation we could have something like the following (if NAXIS1 were, say, 1024, these keywords would describe a spectrum with wavelengths running from 4000.0 to 5258.29 corresponding to pixels 1 through 1024):
The values of the CD matrix are also given in floating point degrees (the example shown indicates a pixel size of 1 arcsecond square). CD1_1 is negative because right ascension decreases with increasing pixel number in a normally oriented astronomical image.
A common definition of the CD matrix is as follows:
where Delta_1 and Delta_2 are the pixel sizes along the X and Y axes, respectively. From the more general form, it is easy to see that a rotation of the coordinate system is shown in the appearance of non-zero cross-terms in the CD matrix.
Please note that the first pixel in an image is numbered (1,1), and whole pixel numbers correspond to the center of the pixel.
Generated with WebMaker
CTYPE1 = `LAMBDA' ! wavelengths
CRPIX1 = 1.0 ! reference pixel
CRVAL1 = 4000.0 ! wavelength is 4000.0 at pixel 1.0
CD1_1 = 1.23 ! wavelength increment is 1.23 per pixel
For an image of the sky, the coordinate system representation might be something like Figure 3.6.
CTYPE1 = `RA---TAN' ! r.a. in tangent plane projection
CTYPE2 = `DEC--TAN' ! dec. in tangent plane projection
CRPIX1 = 400.0 ! reference pixel on first axis
CRPIX2 = 400.0 ! reference pixel on second axis
CRVAL1 = 180.01234 ! r.a. at pixel (400,400) in degrees
CRVAL2 = 30.98765 ! dec. at pixel (400,400) in degrees
CD1_1 = -2.777778E-4 ! change in RA per pixel along first
! axis evaluated at reference pixel
CD1_2 = 0.0 ! change in RA per pixel along second
! axis evaluated at reference pixel
CD2_1 = 0.0 ! change in dec per pixel along first
!axis evaluated at reference pixel
CD2_2 = 2.777778E-4 ! change in dec per pixel along second
! axis evaluated at reference pixel
Coordinate System Representation