ECH_LOAD

Load COMMON blocks describing spectrograph parameters

Description

If a parameter name has been specified, ask the user which file contains the parameters. Otherwise use the one which was supplied.

This file is a text file. Any line beginning with a “!” is a comment line and is ignored. Non-comment lines are split up into space, tab or comma separated tokens (quotes can be used to protect delimiters within tokens should this be necessary) and these tokens are processed in pairs (the number of tokens on a line must be even and will probably usually be 2). The first of each pair is a keyword and the second is a value associated with that keyword. The keyword determines the expected type of the value. All non quoted tokens are converted to upper case.

As the file is processed, there is always a current instrument, a current echelle and a current camera. Initially these are the defaults of “UCLES”, “31” and “LONG” respectively. They are changed by “INSTRUMENT instrument”, “ECHELLE echelle” and “CAMERA camera” entries in the file. Individual spectrograph parameters are each associated with the instrument and with either the echelle or the camera and their entries always apply to the current instrument, echelle and camera.

Instrument-related parameters are:

FCOL
collimator focal length (REAL mm)
NPR
number of prisms in cross-disperser (INTEGER)
ANGLE
prism angle (REAL degrees)

Echelle-related parameters are:

D
number of lines per mm (REAL)
M0
central order number (INTEGER)
WAVE0
central wavelength (REAL Angstroms)
THETAB
blaze angle (REAL degrees)
THETA0
central theta (REAL degrees)
GAMMA0
central gamma (REAL degrees)

Camera-related parameters are:

FCAM
camera focal length (REAL mm)

Note that the order of instruments, echelles and cameras within the file may be significant. For example, the default instrument, echelle or camera may be the first one that was defined in the file (although this routine does not need to make any assumptions about this).

The following example describes UCLES and illustrates a notional short camera of focal length 400mm.

  *       !+ UCLES.DAT
  *       !
  *       !  UCLES spectrograph parameters.
  *       !
  *       INSTRUMENT UCLES
  *          FCOL 6000.0
  *          NPR 3
  *          ANGLE 54.1
  *          ECHELLE 31
  *             D 31.6046
  *             M0 138
  *             WAVE0 4119.68
  *             THETAB 64.66
  *             THETA0 0.0
  *             GAMMA0 0.0
  *          ECHELLE 79
  *             D 79.0115
  *             M0 55
  *             WAVE0 4097.99
  *             THETAB 63.55
  *             THETA0 0.0
  *             GAMMA0 0.0
  *          CAMERA LONG
  *             FCAM 700.0
  *          CAMERA SHORT
  *             FCAM 400.0

This routine should be called before ECH_INIT is called. If it is not called, ECH_INIT will only be able to support the 31 and 79 echelles on the UCLESLONG camera.

Invocation

CALLECH_LOAD (PARAM, FILE, STATUS)

Arguments
READ PARAM CHARACTER

Name of program parameter corresponding to the file to use. If blank, no parameter is read

READ, WRITE FILE CHARACTER

File to use. Default file type is .DAT. Is read if PARAM is blank. Is written if PARAM is non-blank

READ, WRITE STATUS INTEGER

Global status value

Bugs

None known.

Authors

W.F. Lupton AAO (AAOEPP::WFL)