About Chandra Archive Proposer Instruments & Calibration Newsletters Data Analysis HelpDesk Calibration Database NASA Archives & Centers Chandra Science Links

Skip the navigation links
Last modified: December 2006

URL: http://cxc.harvard.edu/ciao3.4/mkarf.html
Hardcopy (PDF): A4 | Letter
AHELP for CIAO 3.4 mkarf Context: tools

Synopsis

Generate an ARF for Chandra imaging data (and grating 0-th order)

Syntax

mkarf  asphistfile outfile sourcepixelx sourcepixely engrid obsfile
detsubsys grating maskfile [pbkfile] [dafile] [mirror] [ardlibparfile]
[geompar] [verbose] [clobber]

Description

`mkarf' generates an OGIP style ARF appropriate for imaging observations. The ARF gives the effective area vs. energy for a given observation and instrument configuration; it has units of [cm**(2) counts/photon]. As input, 'mkarf' requires an aspect histogram (computed by 'asphist') along with a file with complete header information about the observation, such as a Level 1 event file. It outputs an ARF suitable for use in a spectral analysis package such as Sherpa.

The input calibration data (detector quantum efficiencies (QE), mirror effective areas, locations of bad pixels) are obtained using a software library called ARDLIB which is also used by a number of other programs. The ARDLIB library has its own parameter file, ardlib.par, which contains a large number of parameters, of which only a few are actually used by mkarf. For most users, the ARDLIB parameter values will specify files from the calibration database. Consult the ARDLIB documentation for information about specific ardlib.par parameters.

By default, the time and spatial dependence of the ACIS QE due to the buildup of contamination on the optical blocking filter is accounted for automatically. The ACIS QE is adjusted using the current contamination model, interpolating to the observation date taken from the header of the specified 'obsfile'. Alternatively, an observation date can be specified explicitly using the ARDLIB 'TIME' qualifier on the detsubsys parameter. For more information about the ACIS filter contamination model, see the ACIS calibration web page. The contamination correction can be excluded using the ARDLIB detsubsys qualifier "CONTAM=NO".

The definition of the ARF and its use in spectral analysis are discussed by Davis (2001) [ApJ, 548, 1010]. See also the discussion on the CIAO website and, in particular, "The Formal Underpinnings of the Response Functions used in X-Ray Spectral Analysis".

The ARF is computed assuming that the spectral extraction region is large enough to include the entire PSF (e.g. PSF fraction=1.0). If the spectral extraction region excludes part of the PSF, the computed effective area should include only fraction of the PSF contained in the spectral extraction region. For example, if the spectral extraction region includes only 80% of the encircled energy, the computed effective area for that extraction region should be smaller by a factor of 0.8.

It should be clear that the quantitative determination of the encircled energy fraction for a given spectral extraction region depends sensitively on the calibration of the detailed PSF shape as a function of energy and position within the field of view. Because the actual flight PSF is not known to high precision with this level of detail, one should weigh the potential gain associated with choosing a small spectral extraction region against the associated increase in calibration uncertainty.

Example 1

mkarf asphistfile="acis_i3_asphist.fits[asphist]" \
outfile=acis_i3_arf.fits \
sourcepixelx=4139 sourcepixely=4120 \
engrid="grid(rmf.fits[MATRIX][cols ENERG_LO,ENERG_HI])" \
obsfile=evt2.fits detsubsys="ACIS-I3"

Computes an ARF for the point (4139,4120) on ACIS-I3 using an energy grid from the file rmf.fits (in particular columns ENERG_LO and ENERG_HI in the MATRIX block), and writes it to acis_i3_arf.fits. The QE, accounting for the buildup of contamination on the optical blocking filter, is computed using the observation start time, TSTART, taken from the header of evt2.fits.

Example 2

mkarf asphistfile="acis_s3_asphist.fits[asphist]" \
outfile=acis_s3_arf.fits \
sourcepixelx=4146.05 sourcepixely=4045.95 \
engrid="grid(s3_rmf.fits[MATRIX][cols ENERG_LO,ENERG_HI])" \
obsfile=evt2.fits detsubsys=ACIS-S3
pbkfile=acisf063875928N002_pbk0.fits dafile=CALDB

Computes an ARF for the point (4146.0,4045.95) on ACIS-S3. The pbkfile and dafile parameters are set to apply the dead area correction.

Example 3

mkarf asphistfile="acis_s3_asphist.fits" \
outfile=acis_s3nc_arf.fits \
sourcepixelx=3950 sourcepixely=4900 \
engrid="0.1:10.0:0.01" \
obsfile=evt2.fits detsubsys="ACIS-S3;CONTAM=NO"

Computes an ARF for the point (3950, 4900) on ACIS-S3. The ARDLIB qualifier CONTAM=NO means that the QE will not be corrected for absorption by the contamination layer on the optical blocking filter (the default is CONTAM=YES). The energy grid will span the range 0.1-10 keV in steps of 0.01 keV

Parameters

name type ftype def reqd
asphistfile file input   yes
outfile file output   yes
sourcepixelx real input   yes
sourcepixely real input   yes
engrid string input   yes
obsfile file input   yes
detsubsys string input   yes
grating string input NONE yes
maskfile file input NONE yes
pbkfile string input    
dafile string input    
mirror string input HRMA  
ardlibparfile file input ardlib.par  
geompar string input geom  
verbose integer   0  
clobber boolean   no  

Detailed Parameter Descriptions

Parameter=asphistfile (file required filetype=input)

The name of the file containing the binned aspect history in the form of an aspect histogram.

Note that each ACIS CCD has its own GTI file. This means that each chip will have its own aspect histogram file.

Parameter=outfile (file required filetype=output)

The name of the output ARF file.

Parameter=sourcepixelx (real required filetype=input)

Parameter=sourcepixely (real required filetype=input)

These parameters specify the (x,y) sky position [pixels] of the point source, in the appropriate tangent plane coordinate system for the detector.

Parameter=engrid (string required filetype=input)

Energy grid specification string. This string may specify either a file or an explicit energy grid. For example, to read a grid from the block MATRIX of an RMF file called rmf.fits, use:

"engrid=grid(rmf.fits[MATRIX][cols ENERG_LO,ENERG_HI])"

To specify an explicit grid running from 0.3 keV to 10.0 keV in 0.01 keV increment steps, use:

"engrid=0.3:10.0:0.01"

Parameter=obsfile (file required filetype=input)

The name of a FITS file, such as a level 2 event file, containing keywords which specify the mission, detector, SIM offsets, start time, etc.

Parameter=detsubsys (string required filetype=input)

The value of this parameter is passed to ARDLIB to select a particular detector subsystem so that the appropriate QE can be computed. It specifies the specific device (e.g. the specific chip or MCP of the detector) for which the ARF is to be computed. For Chandra, it must specify one of the following detector subsystems:

HRC-I
HRC-S1, HRC-S2, HRC-S3
ACIS-I0, ACIS-I1, ACIS-I2, ACIS-I3
ACIS-S0, ACIS-S1, ACIS-S2, ACIS-S3, ACIS-S4, ACIS-S5
ACIS-0, ACIS-1, ACIS-2, ACIS-3,
ACIS-4, ACIS-5, ACIS-6, ACIS-7, ACIS-8, ACIS-9

For these detector subsystems, the following qualifiers or options are supported:

QE=value
CONTAM=yes|no
UNIFORM (forces QE to be uniform)
IDEAL (equivalent to "QE=1;UNIFORM;CONTAM=NO")
CHIP=value (CHIP=4 ==> ACIS-4 (ACIS-S0))
WINDOW=xmin,ymin,xmax,ymax
REGION=BOX(xcenter,ycenter,xsize,ysize)
REGION=RECTANGLE(xmin,xmax,ymin,ymax)
TIME=value (in seconds since MJDREF)

Note that only simple rectangular regions are supported.

For ACIS, the BPMASK qualifier allows one to include bad pixels selected according to the status column in the bad pixel file:

BPMASK=hex value (Specified as, e.g., 0x39ff)
BPMASK=dec value (Specified as, e.g., 14847)
BPMASK=FAINT (=0x39ff, 14847)
BPMASK=VFAINT (=0x3fff, 16383)

If this option is not present, the default is FAINT.

Parameter=grating (string required filetype=input default=NONE)

This parameter controls whether or not to compute a zeroth order grating ARF. For grating observations, the value is either HETG or LETG. For imaging observations, the value of this parameter is NONE.

Note: For HETG, the PSF in zeroth order is believed to be identical to the imaging PSF. However, for LETG this is definitely not the case and it is unclear whether or not the PSF library will properly handle this case. For this reason, it is recommended that the region be selected to guarantee a PSF fraction of 1.0.

Parameter=maskfile (file required filetype=input default=NONE)

The mask file (msk1.fits) for the observation. The mask file is needed in particular when a window or subarray was used. A value of "NONE" indicates that no mask file will be applied.

Parameter=pbkfile (string filetype=input)

The parameter block file, which defines ACIS pixel clocking parameters, is a standard product of pipeline processing and is available for every observation. This file contains information which defines how long any pixel is exposed before being read-out, which is related to the probability that any pixel will be disabled ("deadened") by cosmic rays. See the description of the "dafile" parameter for more information on ACIS dead area.

Parameter block files have names of the form, "acisf146860615N001_pbk0.fits". The long string of digits refers to the time of observation (seconds since reference date) and "N001" is a revision number.

Since the pbkfile contents are observation-dependent, there is no default other than "NONE". In this case, no dead area correction is applied, and dafile is assumed to have the value "NONE". If pbkfile is set to a valid file, then the dafile parameter must also refer to a calibration file.

The pbkfile parameter is ignored for HRC data.

Parameter=dafile (string filetype=input)

ACIS "dead area" coefficients file, which may have the values "NONE" (no dead area computation), CALDB (for automatic lookup), or an explicit file reference to an ACIS "dead area" coefficients FITS table.

The ACIS dead area refers to a slight decrease in detector efficiency due to the background cosmic ray flux which temporarily renders some pixels useless. The calibration product is a coefficient (per CCD) which gives the fractional area lost (or "deadened") per second. Since the area lost increases with time, the magnitude of the effect depends upon the ACIS clocking parameters (number of rows, window location, frame-time) which determine how long a pixel was exposed to the background cosmic ray flux during the primary exposure and during electronic readout from the frame-store area. For full-frame timed-exposure, the dead area is about 4% at maximum CHIPY and about 2% at the readout. It is smaller for subarrays.

The ACIS clocking parameters required to scale the coefficients in the dafile are contained in the observation-specific parameter block file, which can be set by the associated parameter of this took, "pbkfile". If dafile=NONE, then pbkfile=NONE is assumed.

The dafile parameter is ignored for HRC data.

Parameter=mirror (string filetype=input default=HRMA)

For Chandra, the mirror parameter must be set to "HRMA". However, the following ARDLIB qualifiers are also supported:

AREA=value
SHELL=value (possible values: 1,3,4,6)
BITMAP=value

For example, to compute an instrument map for using shells 1 and 3, which corresponds to the bitmap "1100", use "HRMA;bitmap=1100" for the value of this parameter. To compute using a mirror area of 1, use "HRMA;AREA=1".

Parameter=ardlibparfile (file filetype=input default=ardlib.par)

The name of the parameter file to be used by ARDLIB.

The tool-specific parameter file contains no explicit CALDB parameters. Instead, the CALDB parameters are all contained in a separate parameter file selectable using the `ardlibparfile' parameter; "ardlib.par" is the default file name. Calibration files are specified implicitly via the `DetSubsys' and `Mirror' parameters described below.

Parameter=geompar (string filetype=input default=geom)

The name of the Pixlib Geometry parameter file.

Parameter=verbose (integer default=0)

The verbosity level for messages.

Parameter=clobber (boolean default=no)

If set to yes, existing output files will be overwritten.

CHANGES IN CIAO 3.4

Parameter Changes

Two new hidden parameters have been added to mkarf to allow the ACIS dead area correction to be taken into account: "pbkfile" and "dafile". By default, the correction is "off", i.e. both parameters are set to "NONE". See the individual parameter descriptions for more information.

The "obsfile" parameter is no longer redirected to the value of the "asphistfile" by default. The recommended input to this parameter is now a level 2 event file or similar FITS file.

Notes

The command "mkarf --version" prints the version of mkarf and the associated libraries. This is useful when reporting problems with the tool.

Bugs

See the bugs page for this tool on the CIAO website for an up-to-date listing of known bugs.

Hardcopy (PDF): A4 | Letter
Last modified: December 2006



The Chandra X-Ray Center (CXC) is operated for NASA by the Smithsonian Astrophysical Observatory.
60 Garden Street, Cambridge, MA 02138 USA.    Email: cxcweb@head.cfa.harvard.edu
Smithsonian Institution, Copyright © 1998-2004. All rights reserved.