NAME

xtdrmf - Create a XRISM Xtend energy redistribution matrix file (RMF)

USAGE

xtdrmf infile outfile

DESCRIPTION

The task xtdrmf creates an Xtend RMF file that may be used for spectral analysis with an input spectrum file. The output RMF contains a matrix that, for a given incoming X-ray photon energy, describes the normalized probability of detecting that photon in any PI (pulse invariant) channel. This photon can be redistributed to PI channels away from the expected energy due to interactions with different materials in the detector. For Xtend, the response is composed of: (1) a primary Gaussian component, centered at the expected energy, for photons that interact and are detected completely in the sensitive layer of the detector; (2) a secondary Gaussian sub-peak at slightly lower energy, for photons that lose some charge to pixels below the split threshold; (3) a Gaussian silicon escape peak centered at 1.74 keV below the primary peak, for photons that have some energy absorbed by a CCD Si atom; (4) a Gaussian silicon fluorescence peak at constant energy 1.74 keV, if the Si atom excited in the interaction with the X-ray photon emits a Si K alpha photon that is then detected in a different region; and (5) a constant continuum component extending from the peak energy to 0 eV, produced when a photon interacts near the insensitive detector layer and some charge is lost.

The Xtend response has been measured on the ground using sources of monochromatic X-rays at a number of energies. However, increasing charge transfer inefficiency (CTI) due to radiation damage changes the response, especially the width of the Gaussian features. Therefore, the RMF depends on both observation time and position on the detector. This information is extracted from the header keywords and the weighted map (WMAP) image, respectively, in the input spectrum file. The WMAP is a small counts image of the extracted events, which is used to weight the response parameters in each region before combining to produce a weighted response. Response parameters are defined in the calibration database (CalDB) at a number of energies, and interpolation is performed to place them on the energy grid in the MATRIX extension before the response is calculated.

The output RMF contains a MATRIX extension, which contains the response matrix, and an EBOUNDS extension listing the output energy boundaries of each PI channel.

The energy bin widths of the input energy grid of the RMF may be set with the 'dein' parameter, with 'eminin' and 'nchanin' determining the energy range for those bins (see below for more detail). The recommended energy bin widths are 2 eV and 24 eV for the energies below and above 12 keV, respectively. The default parameter values of 'eminin=200', 'dein=2,24', and 'nchanin=5900,500' are the recommended values. Furthermore, the output energy grid, EBOUNDS, must match the PI energy grid of the spectrum file. Therefore the default parameter values of 'deout=6', 'eminout=0', and 'nchanout=4096' should be used, unless the user wants to change them for their specific purpose. Changing any of the hidden parameter values for this task is not recommended and must be done with care.

PARAMETERS

infile [filename]
Name of input spectrum (PI) file. It must contain a WMAP image rendered in the DET coordinate system in the primary extension.

outfile [filename]
Name of output response (RMF) file.

(rmfparam = CALDB) [filename CALDB|file name]
Name of input file from which the RMF parameters are read.

(eminin = 200.0) [double]
Minimum energy [eV] of the MATRIX input energy grid.

(dein = 2,24) [string]
Widths [eV] of energy bins in each energy interval of the MATRIX input energy grid. A single value (e.g., 2) applies a constant bin width for the entire matrix, starting at 'eminin'. Multiple values separated by commas (e.g., '2,24') create a variable grid spacing starting at 'eminin'. The number of channels in each energy interval must be specified with 'nchanin'. The values can be floating point.

(nchanin = 5900,500) [string]
Number of channels in each energy interval of the MATRIX input energy grid. Combined with the default values of 'eminin' and 'dein', the default value of 'nchanin' means that the MATRIX has 5900 input bins (with 2 eV size) between 200 eV and 12000 eV, and 500 bins (with 24 eV size) above 12000 eV (hence up to 24000 eV). The 'dein' and 'nchanin' parameters must have the same number of intervals. The values of 'nchanin' must be integers.

(eminout = 0.0) [double]
Minimum energy [eV] of the EBOUNDS extension of the output RMF energy grid. This must be must be consistent with the assumed energy grid of the PI spectral file (i.e. 0 eV for Xtend).

(deout = 6.0) [double]
Widths [eV] of the EBOUNDS (extension of the output RMF) output energy grid bins. This must be consistent with the assumed energy grid of the PI spectral file (i.e. 6 eV for Xtend).

(nchanout = 4096) [integer]
Number of channels in the EBOUNDS (extension of the output RMF) output energy grid. This must be consistent with the number of PI channels in the PI spectral file.

(rmfthresh = 1.0e-6) [double]
Lower threshold for the RMF construction. For a given X-ray photon energy, the normalized probability (i.e. a value less than 1) of producing a certain PI value is calculated for each channel and written in the MATRIX extension. If the probability is less than this threshold, 0 (zero) is written for that element. Using the default value (1.0e-6) is secure enough for most cases.

(buffer = -1) [integer -1|0|N]
Rows to buffer (-1=auto, 0=none, N>0=number of rows).

(clobber = no) [boolean yes|no]
Overwrites the existing output file if set to yes.

(chatter = 1) [integer 0|1|2|3]
Chatter level for output. Set to 0 to suppress output, or to 1, 2, or 3 for increasing the chatter of the output.

(logfile = !DEFAULT) [string DEFAULT|NONE|file name]
Log file name. If set to DEFAULT, uses the name of the task and, if preceded by "!", overwrites the file if it exists. If set to NONE, no log file is created.

(debug = no) [boolean yes|no]
Diagnostic output is printed to the screen if set to yes.

(history = yes) [boolean yes|no]
Records task parameters in HISTORY.

EXAMPLES

  1. Create an RMF file for OBSID 100050020 with default values for the energy grid and for other settings.
    xtdrmf infile=xa100050020xtd_p0100004b0_src.pha outfile=response.rmf
    
  2. Create an RMF file for OBSID 100050020 with input energy grid with bins of width 2 eV for the entire energy band of 0.2-24 keV.
    xtdrmf infile=xa100050020xtd_p0100004b0_src.pha outfile=response.rmf dein=2 nchanin=11900
    

SEE ALSO

xtdpi, rslrmf

LAST MODIFIED

June 2, 2023