Per-Observation Detections PHA Files (pha3.fits)
The PHA spectrum file consists of a single FITS format file for each source region of each observation that records the low resolution PI spectrum of the events extracted from the source region, resulting from catalog processing. The PI spectrum is constructed using weighted responses for the areas of the detector over which the source region dithers. A low resolution PI spectrum of the events extracted from the background region is recorded in the FITS HDU (CXC Data Model block) immediately following the source PHA spectrum HDUs.
FITS HDUs (CXC Data Model blocks):
The CSC PHA spectrum files (pha3) can be used from Sherpa, which will automatically recognise the source and background components when the file is read in. If you are using the XSPEC X-ray spectral fitting package then the following limitations may apply (depending on the version of XSPEC in use):
- The file must be uncompressed otherwise the background data will not be read in.
- With older versions of XSPEC the file must be split into separate
source and background files, e.g. with the dmcopy tool:
ciao% dmcopy pha3.fits"[SPECTRUM1]" src_spec.fits ciao% dmcopy pha3.fits"[SPECTRUM2]" bkg_spec.fits
Here is the structure of an example spectrum from CSC 2.0:
unix% dmlist acisf04994_000N021_r0002_pha3.fits.gz blocks -------------------------------------------------------------------------------- Dataset: acisf04994_000N021_r0002_pha3.fits.gz -------------------------------------------------------------------------------- Block Name Type Dimensions -------------------------------------------------------------------------------- Block 1: PRIMARY Null Block 2: SPECTRUM1 Table 4 cols x 1024 rows Block 3: GTI3 Table 2 cols x 2 rows Block 4: GTI2 Table 2 cols x 4 rows Block 5: GTI1 Table 2 cols x 3 rows Block 6: GTI0 Table 2 cols x 4 rows Block 7: GTI6 Table 2 cols x 4 rows Block 8: MASK Image Byte(267x375) Block 9: SPECTRUM2 Table 4 cols x 1024 rows Block 10: MASK2 Image Byte(267x375)
and the columns in the SPECTRUM1 block (this also holds for the SPECTRUM2 block):
unix% dmlist "acisf04994_000N021_r0002_pha3.fits.gz[spectrum1]" cols -------------------------------------------------------------------------------- Columns for Table Block SPECTRUM1 -------------------------------------------------------------------------------- ColNo Name Unit Type Range 1 CHANNEL channel Int4 1:1024 PI 2 PI chan Real8 1.0: 1024.0 pulse invariant energy of event 3 COUNTS count Int4 - Counts 4 COUNT_RATE count/s Real8 0:+Inf Rate
The following set of Sherpa commands load the data, apply a grouping of 20 counts per group over the energy range 0.5 to 7 keV, and then plot the background-subtracted data (see the figure below).
unix% sherpa ----------------------------------------------------- Welcome to Sherpa: CXC's Modeling and Fitting Package ----------------------------------------------------- CIAO 4.11 Sherpa version 1 Wednesday, December 5, 2018 Python 3.5.4 (default, Oct 15 2018, 13:47:46) Type 'copyright', 'credits' or 'license' for more information IPython 6.5.0 -- An enhanced Interactive Python. Type '?' for help. IPython profile: sherpa sherpa In [1]: %matplotlib Using matplotlib backend: TkAgg sherpa In [2]: set_xlog() sherpa In [3]: set_ylog() sherpa In [4]: load_pha('acisf04994_000N021_r0002_pha3.fits.gz') read ARF file acisf04994_000N021_r0002_arf3.fits read RMF file acisf04994_000N021_r0002_rmf3.fits read background file acisf04994_000N021_r0002_pha3.fits sherpa In [5]: notice(0.5, 7) sherpa In [6]: tabstops = ~get_data().mask sherpa In [7]: group_counts(1, num=20, tabStops=tabstops) sherpa In [8]: subtract() sherpa In [9]: plot_data()
Source Region PI
The per-observation PHA FITS file is named: 〈i〉〈s〉〈obs〉_〈obi〉N〈v〉[_〈c〉]_〈r〉_pha3.fits
where 〈i〉 is the instrument designation, 〈s〉 is the data source; 〈obs〉 is the observation identification; 〈obi〉 is the observation interval identification; 〈v〉 is the data product version number; 〈c〉 is the cycle; and 〈r〉 is the region ID, formatted as "rnnnn", where nnnn is the 4-digit region number, formatted with leading zeros. The optional discriminator identified in square brackets is included only for ACIS alternating exposure (interleaved) mode observations.