spacer link to MAST page spacer logo image spacer
 
link to STScI page


HUT Extraction Software

Standard FITS I/O Software

The various FITS files from HUT (idf.fits, cal.fits, and tv.fits) can all be read by any standard FITS I/O library. A summary of some of the most popular ones can be found here.

As a very quick example, here are a few lines that demonstrate how to read the night-only spectrum for an observation of Z-CAM. This assumes you've already downloaded the FITS files.

;; Specify the file to read.
file = "HUT224401cal.fits"

;; Read in HDU2, the second extension, which contains the night-only spectrum.
;; We make use of the Goddard Astronomy Library function MRDFITS.
;; The return value is an IDL structure when the extension is a binary fits table.
fits_exten2_data = MRDFITS(file, 2, fits_exten2_hdr, /SILENT)

;; Create variables that store the wavelength and flux in 1-D arrays.
wls = fits_exten2_data.wave
fls = fits_exten2_data.flux

;; Plot the spectrum.
PLOT, wls, fls, LINESTYLE=0, /YNOZERO


C Routines Provided By HUT Team

The HUT team has also provided a set of C routines to read in the idf.fits files and create cal.fits files. This can be useful if, for example, you wish to modify the inclusion/exclusion of particular photons to re-create a new spectrum. The package can be downloaded here in a gzipped tarball, which contains the necessary C program files, Makefile, and README.