# Part IIBackground Material

### 5 Fibre-fed Spectrographs

Figure 1 shows a (very) schematic diagram of a traditional astronomical single-slit spectrograph. Such an instrument is capable of observing only one object at a time. Typically, a flat opaque plate is placed in the field of view of the telescope, perpendicular to the optical axis. The star-field being observed is imaged on this plate. The plate contains a long, thin slit and the telescope pointing is adjusted until the object being observed (the target object) is imaged on the centre of this slit. Light from the target object passes through the slit, into the spectrograph where it is dispersed (almost invariably by a diffraction grating) and thence it is re-imaged on a two-dimensional panoramic detector. Historically this detector would have been a photographic plate (or even a human eye observing through a travelling eyepiece) though now it is usually a CCD (Charge-Coupled Device). The slit, spectrograph and detector are so aligned that the dispersion direction corresponds to one axis of the two-dimensional CCD array (say the rows, for example). The other axis (say the columns) corresponds to positions along the slit. Thus, the central columns of the CCD see dispersed light from the target object and neighbouring columns see dispersed light from the night sky adjacent to the object.

Such an instrument is not making full use of the imaging capabilities of the telescope; several objects are simultaneously imaged in the field of view, but only one is detected. One way of addressing this deficiency is to place several slits in the field of view, positioned so that light from a separate object passes through each. Many such multi-slit spectrographs have been built. A full discussion is beyond the scope of this cookbook. However, multi-slit spectroscopy has different advantages than fibre spectroscopy and the techniques are briefly compared in Section 9. Fibre-fed spectrographs are another attempt to address the problem and the basics of their operation are simple. A set of optical fibres are accurately positioned in the focal surface of the telescope so that each is illuminated by a target object in the field of view. These fibres are then connected to a series of positions along a single entrance slit for a spectrograph (see Figure 2). A series of spectra, one for each object, are imaged on the CCD detector with (say) each spectrum dispersed along the rows and occupying a distinct, separated range of columns. In essence the operation of a fibre-fed spectrograph is as simple as that.

There are, of course, a number of caveats and complications. Firstly, there is no simple correspondence between the position of any target object in the field of view and the position of its spectrum in the CCD image; it is necessary to keep track of this information separately in order to reduce the observations. Secondly, the fibres have to be positioned so that they are illuminated by the target objects. Thus, they must be reconfigured in new positions for every field of target objects viewed.

Nonetheless, with such an instrument spectra can be obtained simultaneously for large numbers of target objects, with the possible number of targets corresponding roughly to the number of fibres (though some fibres must be reserved for guiding and measuring the sky background). Every technique has its own jargon, and in fibre spectroscopy the number of spectra simultaneously observable is known as the multiplex advantage or multiplex gain, though it is simply the approximate number of fibres. The multiplex advantage (or number of fibres) is not the sole criterion for assessing the usefulness of a fibre spectrograph. Clearly, a fibre-fed system can only be used to its full advantage if there are sufficient objects of interest in a single field of view to occupy all the available fibres. This requirement, in turn, leads to telescope designs with wide fields of view. Another consideration is the proximity with which fibres can be positioned in the focal plane. In addition there are the usual criteria for a spectrograph: wavelength range, resolution, stability, sensitivity etc.

The optical fibres are acting as ‘light pipes’; they simply conduct light emitted by the target objects from the focal plane to the spectrograph entrance slit and emit it effectively unchanged. However, inevitably, there is some loss and degradation of the signal. In particular, fibres output a beam with a smaller focal ratio than the input beam (that is, one which is ‘faster’). This phenomenon is known as focal-ratio degradation (FRD). The effects of FRD can be minimised by careful design of the optical system. Similarly, various types of fibres are available which operate over a range of wavelengths from the near ultraviolet to the near infra-red. The construction and properties of fibres are beyond the scope of this cookbook, but useful reviews have been given by Barden[6], Heacox and Connes[22] and Nelson[36].

Clearly the positions of the fibres, which must be such that light from the target objects falls on them, are unique to each field and the fibres must be moved to different positions when the telescope views a new field. Indeed, positioning the fibres with sufficient accuracy is the greatest technical problem of fibre spectroscopy.

Broadly three different types of system have been used to position fibres: plug-plate systems, auto-fib type systems and MX-type systems. (Auto-fib and MX were early fibre spectrographs.) In a plug-plate system an opaque plate is placed in the focal surface of the telescope, with holes drilled in the plate at the positions of the target objects and fibres attached to the holes. Clearly a separate plug-plate must be prepared in advance for each field viewed. In an MX-type system each fibre is held at the tip of an arm and positioned independently, each arm being controlled by a two-axis actuator. The arms are arranged around the circumference of the field of view in a ‘fishermen round the pond’ arrangement. In autofib-type systems an opaque plate (usually steel) lies in the focal surface of the telescope. The fibres lie flat along the illuminated side of the plate with a small prism at their head to direct light incident on the fibre-head along the fibre. A magnetic button holds the fibre-head in place. A single robot picks up the fibre heads and moves them to the required position. The focal surface of a telescope is not necessarily a flat plane. Fibre spectrographs, of all types, must accurately position the fibre-heads to lie in the the focal surface. This consideration is particularly important for systems such as FLAIR on the UKST because Schmidt telescopes have a spherical focal surface.

### 6 Data Reduction Techniques

Most of the principles of reducing data from fibre-fed spectrographs are very similar to those for slit spectrographs, though there are some procedures which are peculiar to fibre spectroscopy data. The discussion here is a summary which emphasises the features peculiar to fibre spectroscopy. If you are not familiar with slit spectroscopy then there are several good introductory documents which you can consult. Some of these documents are listed below.

In modern slit and fibre spectrographs the detector will usually be a two-dimensional CCD. Various instrumental effects are present in the raw images read from the CCD and these must be removed or allowed for. These effects include: bad pixels, bias in the electronics, dark current and cosmic-ray2 and dust particles. There are several introductory documents describing these effects and the techniques for handling them and the descriptions will not be repeated here. For removing instrumental effects see:

• SC/5: The 2-D CCD Data Reduction Cookbook[18],
• A User’s Guide to CCD Reductions with IRAF[32] (see Section 7.4.2, below, for a discussion of the IRAF data reduction environment).

These documents are mostly concerned with removing instrumental effects from direct images, but are largely applicable to two-dimensional spectra. However, the later stages of reducing direct images and spectra (either fibre or slit) differ. In particular, removing pixel sensitivity variations (‘flat-fielding’) is done differently. Also there are some procedures, such as identifying the spectra in the two-dimensional image and extracting them, which are peculiar to spectroscopy. Some documents specifically about the reduction and calibration of spectroscopic data are:

• SC/7: Simple Spectroscopy Reductions[13],
• A User’s Guide to Reducing Slit Spectra with IRAF[33],
• Guide to the Slit Spectra Reduction Task DOSLIT[45].

These documents describe slit spectroscopy but are mostly also applicable to fibre spectroscopy. Though they describe particular software packages, they are still worth reading even if you do not intend to use the package described; the techniques used are largely independent of the packages and thus the descriptions are still useful. SC/7 is a particularly readable and informative document. Note that it is usually not feasible to flux-calibrate fibre spectra.

The features peculiar, at least in part, to fibre spectroscopy are:

• bookkeeping,
• aperture definition / tramlining,
• extraction,
• scattered light correction,
• flat fielding,
• wavelength calibration,
• sky subtraction.

These points are discussed individually below.

#### 6.1 Bookkeeping

The most obvious addition to traditional spectroscopic techniques required for fibre spectroscopy is the additional bookkeeping needed to keep track of which fibre was targeted on which object (and consequently which object each spectrum was obtained from). It is important that this information is kept track of carefully, otherwise you will become hopelessly confused. A collection of spectra of unknown objects, however well reduced and calibrated, is more or less useless. Usually the data reduction software will keep track of the bookkeeping automatically. If it does not then you must do it manually yourself.

#### 6.2 Aperture definition or tramlining

Figure 3 shows a CCD frame obtained with the WYFFOS/AUTOFIB2 fibre spectrograph. Most fibre spectrographs produce frames of broadly similar appearance. The series of horizontal lines are the individual spectra obtained through the various fibres. In order to extract each spectrum from the image it is necessary to define its spatial extent (or aperture, software aperture or, in this cookbook, footprint) on the CCD frame. There are really three aspects to defining the footprint of each spectrum: locating its position, defining the shape parallel to the dispersion direction and defining the shape perpendicular to the dispersion direction. The need to locate the position is obvious. The remaining two aspects are described below.

Shape parallel to the dispersion direction
Ideally each spectrum is a straight line perfectly aligned along either the rows or columns of the CCD. In practice the spectra are usually slightly curved rather than perfectly straight. This curvature can be caused by distortions introduced by the spectrograph optics and refraction in the terrestrial atmosphere. Spectra imaged on different parts of the CCD frame will not necessarily have precisely the same shape. Even if the spectra are perfectly straight they will not usually be perfectly aligned with the CCD grid.

In order to define the shape along the dispersion direction a locus of points along the middle of the spectrum is defined over its whole length. This process is called tracing the spectrum and the locus is called the trace of the spectrum.

Shape perpendicular to the dispersion direction
Figure 4 shows a row of pixels (or slice) extracted from the CCD frame. The slice is centred on a spectrum and aligned perpendicular to the dispersion direction. The peak in the plot is the spectrum and the flat outer regions the ambient background signal in the CCD frame. Here the slice is crossing the continuum in a well-exposed spectrum. Clearly a slice across an absorption line would show a smaller peak and a slice across the centre of a dark absorption line might hardly deviate from the background.

In general the spectrum will be spread across a range of pixels (as in Figure 4). The actual number depends on the telescope and spectrograph optics and the physical size of the CCD pixels, but it is typically a dozen or so (the spectrum in the figure is actually rather narrower, being about half a dozen pixels wide).

The main information which must be determined is the width of the spectrum in pixels. However, for more sophisticated methods of extracting the spectrum from the frame the shape or profile of the spectrum across the slice may also be important.

The description up to this point is equally applicable to extracting either multiple spectra from fibre spectrograph data or an individual spectrum from single-slit spectrograph data. Indeed, there is a good description of the latter in SC/7 (Sections 4.3 and 4.4) which is mostly applicable to the fibre spectroscopy case.

However, the essential difference for fibre spectroscopy data is that instead of a single spectrum to be extracted there is a whole set of more-or-less parallel spectra to be extracted (recall Figure 3). Defining the footprints of the set of spectra on the CCD frame is called tramlining (because of the resemblance of the spectra to a set of tramlines).

In principle the tramlining could be carried out on the object frame. However, it is better done using an image frame where the fibres were illuminated using a bright, continuous source in order that all the spectra are well-defined along their entire length. Sometimes special frames are acquired for this purpose. Alternatively, flat field frames (see below) are usually suitable. It is usually acceptable to apply the footprints defined from one frame (say a flat field) to another frame (say a target object or arc frame) as long as the instrumental configuration remains unchanged.

#### 6.3 Extraction

Extraction, as its name implies, is the process of extracting a series of one-dimensional spectra, one per fibre, from the two-dimensional CCD frame. It consists of determining the intensity of each spectrum at a series of equally spaced points along the locus of the spectrum using its trace defined during the tramlining.

The simplest way to determine the intensity at each point along the spectrum is simply to average all the points across the width of the spectrum (that is, perpendicular to the dispersion direction), again using the the width determined during the tramlining. A more sophisticated technique is optimal extraction which gives high weight to high signal-to-noise pixels close to the centre of the spectrum and lower weight to lower signal-to-noise pixels close to the edge (see Figure 4). Optimal extraction offers significant advantages for faint, noisy spectra and does no harm for less noisy, well-exposed spectra. Extraction is discussed further in SC/7, Section 4.6.

#### 6.4 Scattered light correction

The signal recorded on the CCD detector for each spectrum includes a contribution from light scattered inside the spectrograph. Typically this scattered light will comprise a uniform component and a local component. The uniform component is, as its name implies, uniform across the detector and is simply proportional to the total light input into the spectrograph. The local component is caused by light scattered from the spectra of bright objects illuminating regions of the detector in the footprints of adjacent spectra.

For emission from a source external to the instrument (either a genuine target object or a ‘sky’ source such as emission from the terrestrial atmosphere) the strength of the recorded signal is simply proportional to the fraction of the light lost in the optical system. Important sources of losses are typically the throughput of the fibres and vignetting in the telescope and they are removed by flat fielding (see Section 6.5, below). However, the intensity of the scattered light does not scale in this fashion and therefore it must be identified and treated separately. For example in dofibers (see Section 7.4.1) it is estimated from the signal recorded in parts of the detector which are outside the footprints of the spectra.

#### 6.5 Flat fielding

Flat field corrections are made in order to allow for simple multiplicative effects in the data. In fibre spectroscopy such effects include:

• the instrumental signature (small-scale variations in the throughput of the instrument optics),
• throughput losses in the fibres (which usually vary between different fibres in the instrument),
• vignetting (the dimming of objects observed towards the edge of the telescope field of view),
• pixel-to-pixel sensitivity variations in the CCD detector.

In fibre spectroscopy it is usually not possible to correct for the sensitivity variations of individual pixels in the detector and the effects of these variations remain as noise in the data.

Flat field corrections in fibre spectroscopy differ from the corresponding operations in direct imaging or single-object spectroscopy. In direct imaging with CCDs the flat field correction is made in order to correct for the individual pixel sensitivity variations in the detector. Image frames are obtained in which the detector is uniformly illuminated (see SC/5). The object frame is then simply divided by the flat field frame. Flat field corrections for single-object spectroscopy are described in SC/7, Section 4.5.

To flat field fibre spectroscopy data the fibres are illuminated with a continuum calibration lamp. The flat field spectra are extracted from the two-dimensional image and converted to one-dimensional spectra in a similar fashion to the target objects. The observed spectrum consists of the intrinsic spectrum of the lamp (which will be more-or-less a black body), with the instrumental signature, fibre throughput losses and vignetting superimposed. Note that the individual pixel sensitivity variations will have been averaged perpendicular to the dispersion direction when the one-dimensional spectrum was constructed.

The flat field spectrum is normalised and, depending on the characteristics of the data, either smoothed or fit by a low-order polynomial. It is then simply divided into the target object spectrum to remove the various multiplicative effects. Remember, however, that the spectrum of the continuum calibration lamp is not flat, so the target object spectra will still show sensitivity variations with wavelength.

The flat field correction is unique to each fibre in each configuration and must be redefined when the fibres are repositioned (for example, because the fibre will be in a different position in the focal surface and hence the vignetting will be different). Flat field frames should have a high signal-to-noise ratio (that is, contain well exposed images of the lamp) in order to reduce noise in the calibration lamp spectra. Consequently flat field frames are also usually suitable for tramlining (see above).

#### 6.6 Wavelength calibration

Each extracted spectrum consists of a list of the intensity at a series of positions along the central locus of spectrum. Because the spectra are usually both bent and misaligned with the CCD grid these positions will not generally correspond precisely to the positions of pixels in the CCD. However, they are in units of pixel positions. The next step is to convert the positions into genuine wavelengths, typically in Ångström.

This calibration is achieved using calibration frames. Arc calibration frames are produced by illuminating the fibres with an arc calibration lamp. The spectrum of such a lamp is primarily a set of emission lines. Briefly, the emission lines have a known wavelength and their positions in the calibration spectra can be measured. It is then possible to fit the relation between position and wavelength using a low-order polynomial. This relation is applied to the spectra of the target objects to calibrate them into wavelength.

The details of the way in which the calibration lines are identified and the fit made vary. You may be required to identify some (or all) of the emission lines from a spectral atlas, or the identification may be completely automatic. If you have to identify the lines manually you should try to ensure that you find lines spread along the entire range of the spectrum (to minimise errors of interpolation and extrapolation). You will probably also have to choose the order of the polynomial fit between wavelength and position: too low an order will leave systematic residuals and too high an order will introduce spurious effects. The traditional wisdom is that arc frames should be exposed both before and after target object frames and the results averaged in order to reduce systematic effects. However, spectrographs mounted on a Nasmyth platform or the dome floor are usually extremely stable and in these cases fewer arc frames may be adequate. Applying the wavelength calibration to the target spectra is often called making the dispersion correction. Wavelength calibration is discussed further in SC/7, Section 4.7.

In fibre spectroscopy it is usually necessary to perform wavelength calibration prior to sky subtraction.

#### 6.7 Sky subtraction

Sky subtraction is one of the most critical areas of fibre spectroscopy. It is closely related to the correction for scattered light (see Section 6.4) and the flat field correction (see Section 6.5) for throughput losses in the fibres and vignetting. The corrections are more difficult to estimate than in the case of slit spectroscopy. However, if the appropriate procedures are applied carefully then it is possible to obtain accurate results. In a seminal paper Wyse and Gilmore[51] give a detailed and thorough description of the sources of error and discuss how to correct for them. The following discussion is largely based on this paper, though it is still well worth reading the original. Another useful and detailed description is given by Watson et al.[49].

Consider a spectrum corrected for scattered light, flat fielded and wavelength calibrated, as described above. The resulting spectrum is the sum of the spectra of the astronomical target object and emission from the night sky. In order to determine the spectrum of the target object it is necessary to estimate the contribution of the night sky and subtract it from the observed spectrum. The accuracy with which the sky contribution can be estimated and the other calibrations made will largely determine the accuracy with which the spectrum of the target object can be determined. The size of the sky correction varies with the angular size of the field of view of the fibre; a fibre with a wide field of view will see more sky than one with a narrow field of view.

In principle the sky and scattered light contributions can vary in both space and time. Indeed, in principle, the target object spectrum can also vary with time, though in practice such variations can almost always be considered negligible on the time-scale of a typical exposure and ignored. The properties of the sky contribution is briefly discussed below and then the techniques for correcting for it considered.

##### 6.7.1 Sky emission

The main components of emission from the night sky are the aurora, zodiacal light, atmospheric emission and faint ‘background’ astronomical sources. The zodiacal light and faint astronomical sources have spectra similar to the Sun (the zodiacal light is, of course, just sunlight reflected off interplanetary dust). The aurora and atmospheric emission have primarily (but not exclusively) emission spectra. Emission and absorption lines originating in the terrestrial atmosphere are often called telluric lines. Wyse and Gilmore[51] give summary details of the atmospheric emission and Chamberlain[11] gives a thorough description. However, the upshot is that atmospheric emission is more important in the red than the blue, with the OH (Meinel) bands often being particularly prominent at wavelengths longer than about 6500Å. The atmospheric components variously show spatial changes on scales of a degree or more and of less than a second of arc, but not on intermediate scales. They can, however, show temporal changes on time-scales which are short compared to a typical astronomical exposure.

Of the astronomical sources, complex resolved backgrounds, such as diffuse Galactic light or a resolved galaxy, can show spatial variations on all scales up to degrees. However, away from the Galactic plane and large, nearby galaxies, such complex backgrounds are rare and the astronomical background is usually dominated by light from faint, unresolved galaxies. This distribution is variable on scales of less than a second of arc, but not on larger scales (unless the region observed is in a galaxy cluster). Furthermore, the galaxy luminosity function is such that usually the field of view probably will not contain a rare relatively bright background galaxy, but if by chance it does then this galaxy will dominate the observed background. This property of the luminosity function has consequences for determining the background level (see below).

The uniquely wide field of view of FLAIR (see Section 7.3) means that spatial variations on scales of degrees are more important for it than for other instruments with smaller fields of view.

##### 6.7.2 Correction procedure

This section considers the procedures for correcting for sky emission. Two techniques are in common use: simultaneous sky exposure and separate sky frames. In both cases the target object spectra should previously have been corrected for instrumental scattered light and flat fielded.

Recall that for isolated objects far from the Galactic plane and bright galaxies there is (usually) no structure in the sky background on spatial scales ranging from seconds of arc to degrees but there are temporal variations on the time scale of a typical exposure. Consequently there is no advantage in measuring the sky background very close to the target object: measurements within a degree or so are just as good. Conversely, because the background varies with time there is an advantage in measuring it simultaneously with measuring the target objects. As its name implies the simultaneous sky exposure technique measures the sky and target objects simultaneously, whereas in the separate sky frames technique they are measured sequentially. Thus, the simultaneous sky exposure technique is usually preferable.

Simultaneous sky exposure
When the target objects are being observed a few fibres are not allocated to targets, but rather are positioned so that they point at patches of blank sky. The sky spectrum is then determined from these fibres. Usually 5 to 10% of the fibres are used in this way3.

In Section 6.6 it was stated that the spectra should be wavelength calibrated prior to sky subtraction. The reason for performing the operations in this order is that light from the sky and object falls on different parts of the detector and because of distortions in the spectrograph the shape of the spectra will not be identical. If they are subtracted prior to wavelength calibration the pixels will not be properly aligned, resulting in spurious artifacts such as residual ‘P Cygni’ type profiles4 for the atmospheric lines. The effect of poor wavelength calibration has been discussed comprehensively by Parry and Carrasco[42].

As described in Section 6.7.1, if a rare, relatively bright background galaxy happens to fall in the field of view of a fibre it will dominate the sky background in that fibre. Consequently, simply taking the mean of all the sky fibres is not usually the best way to estimate the most likely sky spectrum. Rather, it is better to find the total counts for each spectrum and exclude the extreme spectra in the resulting distribution, thus avoiding contamination by rare, relatively bright background galaxies.

Clearly the simultaneous sky exposure technique does not work well if the sky background is not flat.

Separate sky frames
Here, before or after acquiring spectra of the target objects (or both) the pointing of the telescope is offset slightly so that all the fibres point at the night sky5 and a frame of spectra of the sky background acquired. The genuine target spectra can then be sky-subtracted using the sky spectrum from the corresponding fibre in the sky frame. Here there is less need for fibre throughput and vignetting corrections as both the object and the sky used to correct it are measured through the same fibre.

The technique is viable only if the sky background is constant on time-scales longer than the exposure time. It also makes less effective use of the telescope than the simultaneous sky exposure technique because approximately half the observing time is spent observing sky. However, a few separate sky frames can provide a useful check that the simultaneous sky exposure technique is working correctly.

##### 6.7.3 Other techniques

Various more complicated techniques have been proposed, for example by Lissandrini et al.[30] or Watson et al.[49], though these are not usually in routine use.

### 7 Instruments and Software Available

The principal common-user fibre-fed spectrographs currently available to UK astronomers are:

• 2dF,
• WYFFOS/AUTOFIB2,
• FLAIR.

The characteristics of these instruments are summarised in Table 1 and they are described briefly below. All three instruments have been described numerous times in the various conference proceedings listed in Section 2. In the following descriptions only the most recent of the references is given. The three instruments each have their own data reduction software, which is also described. In the cases of WYFFOS/AUTOFIB2 and FLAIR this software is based on the IRAF package dofibers. Additional sections describe dofibers and the underlying IRAF environment.

 Instrument Telescope Field of view Maximum Multiplex (minutes of arc) resolving power advantage 2dF AAT 3.9m 120 4000 400 WYFFOS/AUTOFIB2 WHT 4.2m 60 8000 150 FLAIR UKST 1.2m 390 2000 90

Table 1: Common-user fibre-fed spectrographs

#### 7.1 2dF

The 2dF (Two-degree Field) instrument on the Anglo-Australian 3.9m Telescope (AAT) has a two degree field of view (as its name implies) and 400 fibres. The basic components of the system are the correction lens optics (which give good images over a wide field), a robot to position the fibres (somewhat similar to auto-fib) and two identical spectrographs (each accommodating 200 fibres). The whole assembly is mounted on a self-contained ‘top-end’ ring which can be removed from the telescope (see Figure 5). The typical time for the robot to position the fibres is about an hour (approximately eight seconds per fibre), similar to typical exposure times. In order to avoid wasting observing time two complete sets of fibres are provided, attached to a rotating tumbler mechanism. One set is configured whilst the other is being used to observe. When the observation finishes the tumbler rotates to bring the newly-configured set of fibres into the optical path ready for the next observation.

The 2dF has been described by Cannon[10] and a user guide is available[3]. Further information can be found on the Anglo-Australian Observatory (AAO)’s Web pages at URL:

http://www.aao.gov.au/2df

including a hypertext version of the manual and a postscript version which can be downloaded and printed.

##### 7.1.1 Software

A comprehensive suite of software, 2dFDR, has been developed specifically for reducing 2dF data. It was mostly written by Jeremy Bailey of the AAO. It includes the following facilities: bias and dark subtraction, tram-line mapping of the spectra from individual fibres on the CCD and their extraction, arc identification, wavelength calibration, fibre throughput calibration and sky subtraction. The 2dF data reduction software is comprehensively documented in the 2dF User Manual[3]. The software is mostly written in Fortran and uses various Starlink subroutine libraries. It is controlled from an easy-to-use graphical user interface (GUI) written in tcl/tk.

2dFDR is available for both the Digital/Alpha and Sun/Solaris versions of Unix. A sample dataset is also available. Both the software and sample data can be downloaded by anonymous ftp from the AAO. If you are not familiar with the ftp utility then seek assistance from your site manager. The details are as follows.

 ftp site: ftp.aao.gov.au directory: /pub/2df files: 2dfdr_alpha.tar.Z Digital/Alpha version 2dfdr_solaris.tar.Z Sun/Solaris version sample_data.tar.Z sample data

The files are compressed tar archives. Remember to set ftp to binary mode prior to retrieving copies. Decompress the files using Unix command uncompress (sic). 2dFDR requires some 25Mb of disk space and sample data needs a further 40Mb. Twice this amount is required if both the extracted files and the tar archives are to be resident on disk simultaneously. See the README files included in the archives for further details. Section 13 is an example of installing 2dFDR and using it to reduce sample data.

2dF data files are stored using the standard Starlink NDF ($n$-dimensional Data Format; see SUN/33[47]) format. They can be converted to the widely-used standard FITS6 (Flexible Image Transport System) format using the Starlink CONVERT package (see SUN/55[16]). Use application ndf2fits with the proexts (propagate extensions) option. The auxiliary information in the NDF giving details of the individual fibres is appended to the FITS files as a binary-table extension. This binary table can be accessed using the catalogue and table manipulation package CURSA (see SUN/190[17]). 2dF FITS files can be converted back to the original NDF format using the CONVERT application fits2ndf.

2dF data can also be successfully reduced using the IRAF package dofibers (see Section 7.4.1). The AAO Web pages include some tips on using dofibers with 2dF data. You are likely to need to increase parameter min_lenuserarea before using IRAF with 2dF data; see Section 7.4.3 for details.

#### 7.2 WYFFOS/AUTOFIB2

The 4.2m William Herschel Telescope (WHT) has a prime-focus corrector and associated
atmospheric-dispersion compensator with a one degree field of view. The WYFFOS/AUTOFIB2 system exploits this field of view with up to about 150 fibres. WYFFOS and AUTOFIB2 are separate components. AUTOFIB2 is an auto-fib type robot fibre positioner (indeed, it is a descendent of the original auto-fib) mounted at the WHT prime focus. WYFFOS (WYde-Field Fibre Optics Spectrograph) is a fibre-fed spectrograph. It is permanently mounted on one of the Nasmyth platforms and consequently is very stable.

WYFFOS/AUTOFIB2 has been described by Watson[48] and further information is available on the Instituto de Astrofisica de Canarias’ Web pages at URL:

http://www.ing.iac.es

including a hypertext user manual.

##### 7.2.1 Software

WYFFOS/AUTOFIB2 data are reduced using wyf_red, a special-purpose IRAF script written by Jim Lewis. This script uses the IRAF application dofibers (see Section 7.4.1, below) and other IRAF applications. Unlike the basic dofibers it will automatically perform the routine CCD processing (bad pixel removal, flat-fielding, debaising etc). wyf_red will also handle wavelength calibration and sky subtraction.

A comprehensive manual for wyf_red, the WYFFOS Data Reduction Manual[29], is available. Copies of the software and manual can be downloaded from the WYFFOS/AUTOFIB2 section of the IAC Web pages.

WYFFOS/AUTOFIB2 data are exported as FITS files. Prior to using wyf_red they must be converted to the IRAF format using the IRAF command rfits. Note however that the IRAF parameter min_lenuserarea must be increased in order to accommodate WYFFOS headers. This change must be made before running rfits to import the files. See Section 7.4.3, below and the Getting Started section of the wyf_red manual for details.

There is no example of reducing WYFFOS/AUTOFIB2 data in the present cookbook. However, the examples of reducing Hydra (Section 11) and FLAIR (Section 12) data with IRAF are sufficiently similar (because they also use dofibers or the closely related dohydra) that it is worthwhile trying them before attempting to reduce WYFFOS/AUTOFIB2 data.

#### 7.3 FLAIR

FLAIR (Fibre-Linked Array-Image Reformatter) is a fibre-fed spectrograph for the 1.2m UK Schmidt Telescope (UKST). Strictly speaking the current version of the instrument is FLAIR II, a development of the original FLAIR. However, for simplicity it will simply be referred to as FLAIR in the present cookbook. FLAIR is able to exploit the 40 square degree wide field of view of the UK Schmidt Telescope, giving it a uniquely wide field of view for a fibre-fed spectroscopic system. Typical dwell-times on single fields are one to two hours, though long dwell-times of up to seven hours are possible. FLAIR is suitable for observing moderately faint objects ($B\le 18$) with number densities in the range 1–10 per square degree. The spectrograph is mounted on the dome floor and consequently is extremely stable. Originally the fibres were positioned using a technique unique to FLAIR. They were cemented onto a copy photographic plate of the field to be observed. The plate was placed in a modified plate holder, with the fibres on the illuminated side of the plate. Small prisms on the head of the fibres directed the incident light along the fibres. Currently the fibres are mounted on top of a film copy of the target field using magnetic buttons. FLAIR should be replaced by the 6dF[39] around the year 2001.

FLAIR has been described by Parker[37] and further information is available on the AAO’s Web pages at URL:

including a hypertext user manual.

##### 7.3.1 Software

FLAIR data are reduced using a set of IRAF scripts based around the IRAF application dofibers (see Section 7.4.1). Before running the FLAIR scripts the CCD frames must be corrected for instrumental effects (allowing for bad pixels, flat-fielding, debiasing etc). These operations are also most conveniently done with IRAF.

A manual for reducing FLAIR observations is available: FLAIR Data Reduction with IRAF[20]. Another useful document is A User’s Guide to CCD Reductions with IRAF[33]. Copies of the FLAIR software and the manual can be downloaded from the FLAIR section on the AAO Web pages (see Section 7.3). Alternatively, they be retrieved by anonymous ftp. The details are as follows:

 ftp site: ftp.aao.gov.au directory: /pub/flair files: README instructions flair.tar.Z FLAIR IRAF scripts flair_iraf.ps.Z user manual (postscript)

Files flair.tar.Z and flair_iraf.ps.Z are compressed. Remember to set ftp binary mode prior to retrieving them. Decompress the files using Unix command uncompress (sic). See file README for details of installing the IRAF scripts.

FLAIR data are usually exported as FITS files and then converted to the IRAF format using the IRAF command rfits. Note, however, that as for WYFFOS/AUTOFIB2, the IRAF parameter min_lenuserarea must be increased before importing the data in order to accommodate the FLAIR headers. See Section 7.4.3, below and the Setup section of the FLAIR II data reduction manual for details.

Section 12 is an example of reducing FLAIR observations with dofibers. FLAIR data can also be reduced using the Starlink packages Figaro (see SUN/86[43]), CCDPACK (see SUN/139[19]) and KAPPA (see SUN/95[14]), though this is unusual.

The WYFFOS/AUTOFIB2 and FLAIR software is based on the package dofibers which itself runs under the IRAF environment. These items are briefly described below.

##### 7.4.1 dofibers

dofibers is a general-purpose IRAF application written by Francisco Valdes for reducing fibre spectroscopy observations and is not tied to any particular instrument. It provides facilities for the extraction, flat-fielding, fibre throughput correction, wavelength calibration and sky subtraction of fibre spectra. It is an IRAF command language script which invokes other IRAF applications.

dofibers is the usual method of reducing FLAIR observations and has been used successfully to reduce 2dF data. The reduction procedures for WYFFOS/AUTOFIB2 are based on dofibers but it cannot be used directly in this case because in WYFFOS/AUTOFIB2 the fibre ends are positioned in three parallel rows in the spectrograph slit rather than the single row expected by dofibers.

dofibers is documented in the Guide to the Multifiber Reduction Task DOFIBERS[44]. Both the software and manual are available as part of IRAF (see the following section).

##### 7.4.2 IRAF

IRAF (Image Reduction and Analysis Facility) is a powerful and comprehensive environment for reducing and analysing astronomical data. It was developed at the National Optical Astronomy Observatories (NOAO), Tucson and is in widespread use around the world. IRAF has its own data file format, command language, on-line help system and programming language. It is a modular system. The basic core, which is always present, provides general facilities for image processing and data reduction. For more specialised tasks, such as reducing spectroscopic data, additional packages are loaded to augment the core system.

Software for processing most sorts of astronomical data is available for the IRAF environment. For example, dofibers, the general-purpose package for processing fibre spectroscopy data discussed in Section 7.4.1, runs as part of IRAF. Similarly, the special-purpose packages for reducing WYFFOS/AUTOFIB2 and FLAIR data (see Section 7.2.1 and 7.3.1 respectively), which themselves use dofibers, are optional IRAF packages.

The use of IRAF on Starlink systems is described in SG/12: An Introduction to IRAF[34]. If you are not familiar with IRAF this document is a convenient introduction. Another useful document is A Beginner’s Guide to Using IRAF[8]. SG/12 includes details of how to obtain copies of IRAF manuals. IRAF is a complex and in some ways non-intuitive system and it is well worth taking the time and trouble to learn the basics of its operation before attempting a complicated data-reduction task. The Beginner’s Guide is an accessible and thorough document and is a good place to start. Even if you are already familiar with IRAF it is still worthwhile having a look at the Beginner’s Guide because it may well still contain useful information which is new to you. IRAF is installed at most Starlink sites. If it is not installed at your site and you wish to obtain a copy then SG/12 contains some useful notes. However, you will probably need to arrange for your site manager to carry out the actual installation.

##### 7.4.3 Using IRAF with fibre spectroscopy data

FITS files containing observations made with fibre spectrographs usually have large headers (because of all the bookkeeping associated with the individual fibres) and this is the case with files generated by the 2dF, WYFFOS/AUTOFIB2 and FLAIR. The headers generated by these instruments are larger than IRAF accommodates by default when it reads FITS files. Thus, it is necessary to reset the parameter min_lenuserarea, which specifies the maximum header size, prior to importing the FITS files. Table 2 gives the minimum required value for each instrument (larger values may, of course, be used). The simplest way to reset min_lenuserarea is to use the IRAF customisation login file supplied with SG/12[34]. In this case the parameter is set to an appropriate value when IRAF starts. Alternatively, you can reset the value manually from the IRAF command line. For example, for WYFFOS/AUTOFIB2 you would type:

reset min_lenuserarea  =  300000

 Instrument min_lenuserarea 2dF 128,000 WYFFOS/AUTOFIB2 300,000 FLAIR 40,000

Table 2: Minimum permitted values of IRAF parameter min_lenuserarea for use with fibre spectrographs

### 8 Generating Target Positions

Positioning the fibres correctly in the focal surface so that light from the target objects falls on them is perhaps the greatest technical challenge of fibre spectroscopy. However, most of the difficulties and complexities of mechanically positioning the fibres will not concern you as a user. Nonetheless, you will need to compile a list of accurate celestial coordinates for all your target objects. Typically, some time before the observations are made you will supply this list to the support staff of the telescope where you are planing to observe. Usually each fibre has a limited field of view and hence accurate coordinates are required. For example, for the 2dF they should be accurate to within 0.25 seconds of arc. The manual for the instrument that you are using should give the required tolerance.

You will necessarily know some details about your target objects (otherwise you would not be intending to observe them) and these details will almost certainly include their celestial coordinates expressed to some level of accuracy. If you know the coordinates to the accuracy required by the instrument then you can simply compile a list without further ado. This section gives a couple of hints about how you might proceed if you know only approximate coordinates which are insufficiently accurate to position the fibres.

If your objects are included in one of the general-purpose on-line object databases, such as SIMBAD for Galactic objects or NED for external galaxies7 then you can use the coordinates that they give for your objects. You should be aware, however, that these databases contain heterogeneous information obtained from a variety of sources and you should ensure that the coordinates given are of sufficient accuracy.

If you cannot obtain sufficiently accurate coordinates from published sources or general-purpose on-line databases then it may be possible to use the catalogues and databases compiled by scanning Schmidt survey plates with either the APM or SuperCOSMOS fast microdensitometers in Cambridge and Edinburgh respectively. The coordinates in these catalogues and databases are sufficiently accurate for positioning 2dF fibres. Currently the APM catalogue of the northern sky is available on-line and a catalogue of the southern sky is being compiled. Brief details of the catalogues are as follows. The northern catalogue is based on O and E survey plates and covers most of the northern sky to within 20${}^{\circ }$ of the Galactic plane. The southern catalogue is based on the UKST J and SES R surveys. Compilation of the catalogue is still in progress and data are added as they become available. Further details of the catalogues and instructions on how to extract lists of target objects can be found on the Web pages of the Astronomy Survey Unit at the Institute of Astronomy, Cambridge. See URL:

Currently SuperCOSMOS is scanning the J, R and I UKST surveys. The South Galactic Cap and Magellanic Clouds have been scanned and will be available on-line from Summer 1999. Additional fields are being added, spiralling out from the South Galactic Cap. If your target objects are in a region of sky which has not yet been scanned then it will usually be possible to locate and scan a suitable plate for you. However, you should consider this latter option as a method of ‘last resort’, as the scanning schedule for the microdensitometer is planned well in advance. An outline of the various procedures follows.

(1)
Check the SuperCOSMOS on-line databases to see whether the region of sky containing your objects is available. The databases can be accessed from the SuperCOSMOS Web pages at URL:

You should retrieve the catalogue of objects found in your region of sky formatted as a FITS table.

(2)
If your region of sky is not yet available then you will need to identify a suitable plate of the region. You can search the UKST plate catalogue from URL:

Once you have identified a plate you can arrange for it to be measured by SuperCOSMOS. Details are available at URL:

For further information send an e-mail message to username hmg@roe.ac.uk. You should specify that the list of objects detected (the ‘IAM data file’ in SuperCOSMOS jargon) is to be returned to you formatted as a FITS table. Usually there will be a delay of a couple of weeks before your plate is scanned.

(3)
Typically SuperCOSMOS finds upwards of some hundreds of thousands of objects on a Schmidt plate. You need to identify the few hundred corresponding to your target objects from amongst all the objects that SuperCOSMOS has detected in the selected region. You can identify your objects using the catalogue manipulation package CURSA (see SUN/190[17]). First prepare a table containing the known approximate coordinates of your objects formatted as a CURSA STL list (which is simply an easy-to-prepare text file; see SUN/190 for details). Then find the objects in the SuperCOSMOS data file with similar coordinates using CURSA application catpair. The output catalogue generated by catpair will include the accurate coordinates determined by SuperCOSMOS.

### 9 Comparison With Other Techniques

In addition to fibre spectroscopy there are two other major techniques for obtaining multiple spectra simultaneously: objective-prism spectroscopy and multi-slit spectroscopy. This final section briefly compares fibre spectroscopy with these techniques. They are discussed separately below.

#### 9.1 Objective-prism spectroscopy

Objective-prism spectroscopy is rather different to fibre spectroscopy and is not really a direct alternative. A low dispersion prism (or a grating) is placed in front of the telescope objective and produces low resolution spectra in the focal surface of all the objects in the field of view. The technique has been used for many years, mostly in conjunction with Schmidt telescopes. Because spectra are produced throughout the field of view, which is typically large for Schmidt telescopes, the images are usually recorded on photographic plates. A good-quality low dispersion prism plate obtained with the UKST might typically contain some 60,000 images. However, it is only possible to produce spectra with relatively low dispersion. Objective-prism spectra are typically used for classification surveys and searches for ‘unusual’ objects such as quasars, blue stars and emission line objects. Considerable archives of prism plates have been accumulated at various observatories around the world and various programmes are still in progress, for example with the UKST. For recent reviews of objective prism work see Parker and Hartley[38] and references therein. There is a brief introduction to objective-prism techniques in Walker[46], pp164-165.

#### 9.2 Multi-slit spectroscopy

Multi-slit spectroscopy is a realistic alternative to fibre spectroscopy. Multi-slit spectroscopy is identical to traditional spectroscopy of one object using a single slit except that, as its name implies, there are several slits in the field of view, each allowing light from a different object to pass into the spectrograph and form spectra on the detector. The engineering problem of configuring the slits to be in the correct positions to pass light from the target objects is usually solved by preparing a separate plate (or mask) for each field observed. The required slits are simply drilled in the appropriate positions. This approach is analogous to preparing a plug plate in fibre spectroscopy.

The advantages of multi-slit spectroscopy are that it has all the accuracy and capabilities of single-slit spectroscopy. It is feasible to carry out flux calibration. Accurate sky subtraction is certainly easier and perhaps more accurate (though the arguments are not simple; see Section 6.7 above and Wyse and Gilmore[51]). Also there are no throughput losses associated with passing light through the fibres.

The disadvantages are that both the field of view and the multiplex advantage are usually smaller than for fibre spectroscopy. A modern multi-slit spectrograph might typically have a field of view of 10 minutes of arc in diameter, compared with, for example, the 2${}^{\circ }$ diameter field of the 2dF. Also, in order to avoid overlapping spectra the number of spectra which can be simultaneously recorded is usually limited to tens rather than hundreds (although Allington-Smith et al.[1] quote the theoretical maximum multiplex advantage of the GMOS multi-slit spectrographs being built for the Gemini telescopes as 600. Of course, this maximum value will not be attainable in most fields). The necessity of avoiding overlapping spectra can also limit the positioning of the slits to locations that are not optimal for the scientific investigation being conducted. A final consideration is that a multi-slit spectrograph attached directly to the telescope may be less stable than a fibre spectrograph mounted on the dome floor or a Nasmyth platform.

2Astronomers usually refer to spurious signals in CCD frames caused by ionising radiation as cosmic-ray hits or cosmic-ray events. However, these terms are slightly misleading as the ionising events are as likely to be due to background terrestrial radiation as cosmic-rays.

3Typical numbers might be: about twenty sky fibres for the 2dF, between ten and twenty for WYFFOS/AUTOFIB2 and three to ten for FLAIR.

4A P Cygni line profile is one in which the line shows adjacent emission and absorption. The name comes from the variable star P Cygni, whose spectrum shows such features. Of course, in P Cygni and similar stars the effect is caused by physical processes in the stellar atmosphere, not defective calibration.

5There is always the chance, of course, that by inadvertence a random field object could be brought into the field of view of an individual fibre.

6The original FITS format was proposed by Wells et al.[50] in 1981. However, it has been developed and enhanced over the years. The FITS standard is now maintained and documented by the FITS Support Office of the Astrophysics Data Facility at the NASA Goddard Space Flight Center (see URL: http://www.gsfc.nasa.gov/astro/fits/fits_home.html). Though FITS is basically an astronomical format it is sometimes mentioned in books about standard image formats. See, for example, Graphics File Formats by Kay and Levine[27].