arf2arf1 - convert a Type 2 ARF file to a Type 1 ARF file
arf2arf1 infile outfile
The Ancillary Response File (ARF) is used in combination with the detector Redistribution Matrix File (RMF) by the XSPEC spectral fitting package. In a Type 2 ARF file multiple ARFs are packed into a single binary table, one per row. A Type 1 ARF file, on the other hand, only contains a single ARF in each binary table extension. The process of converting a Type 2 ARF to a Type 1 ARF involves expanding each row of the Type 2 file into a separate binary table extension in the Type 1 file.
Both types of ARF tables contain 3 columns containing floating point data values: 'ENERG_LO', 'ENERG_HI', and 'SPECRESP'. The difference is that these are scalar columns in Type 1 files and vector columns in Type 2 files. The 3 vectors in the Type 2 file must have the same length. The number of rows in the output Type 1 ARF table extensions will be equal to the length of the vectors in the Type 2 files.
1. Convert the input Type 2 ARF to a Type 1 ARF
ft> arf2arf1 inarf.fits outarf.fits