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

Skip the navigation links
Last modified: 1 Dec 2006
Hardcopy (PDF): A4 | Letter

Compute LETG/HRC-I Grating ARFs

[CIAO 3.4 Science Threads]



Overview

Last Update: 1 Dec 2006 - updated for CIAO 3.4: CIAO version in warning; ChIPS version; parameter file updates for mkgarf

Synopsis:

mkgarf creates a grating ARF for a particular order and grating of an observation.

Purpose:

To create grating ARFs for an LETG/HRC-I observation.

Read this thread if:

you are working with an LETG/HRC-I observation and intend to model and fit the spectra in Sherpa.

Calibration Updates:

  • CALDB v2.17 (1 Oct 2002): A new HRC QE file (hrciD1999-07-22qeN0006.fits) was added to the CALDB. This file will automatically be picked up by the tool mkgarf via ardlib.par.

Related Links:

Proceed to the HTML or hardcopy (PDF: A4 | letter) version of the thread.




Contents



Get Started

Sample ObsID used: 1801 (LETG/HRC-I, PKS2155-304)

File types needed: evt2; pha2; asol1; bpix1; dtf1

If you created a new bad pixel file by running the Creating a New Observation-Specific HRC Bad Pixel File thread, make sure that you have set up ardlib to use the same bad pixel file.



Determine Orders

An ARF needs to be calculated for each order in the observation. We can use Prism to examine the pha2 file and determine how many orders there are:

unix% prism hrcf01801N002_pha2.fits &

The tg_m column indicates the order of the observation (+/- 1, +/- 2, +/- 3) and the tg_part column indicates the grating (1 = HEG, 2 = MEG, 3 = LEG). In this example [Link to Image 1: PHA2 file displayed in prism], there are two rows for the LETG observation. HRC-I cannot resolve orders; +/- 1 refer to the total positive- and negative-side counts respectively.



Compute the Aspect Histogram (asphist)

The aspect solution files are used to create a binned histogram detailing the aspect history of the observation:

unix% punlearn asphist
unix% pset asphist infile=pcadf082337011N002_asol1.fits
unix% pset asphist outfile=asphist.fits
unix% pset asphist evtfile="hrcf01801N003_evt2.fits[chip_id=0]"
unix% pset asphist dtffile=hrcf01801_000N003_dtf1.fits
unix% asphist
Aspect Solution List Files (pcadf082337011N002_asol1.fits): 
Aspect Histogram Output File (asphist.fits): 
Event List Files (hrcf01801N003_evt2.fits[chip_id=0]): 
Live Time Correction List Files for HRC (hrcf01801_000N003_dtf1.fits): 

# asphist (CIAO 3.4): WARNING: skipping 8 livetime correction records
  (from time: 82336842.920687 to time: 82337011.020694)

In many cases there will be more than one asol1.fits file for an observation. All the files must be input to the infile parameter, either as a list or as a stack (see ahelp stack for more information).

The content of the parameter file may be checked using plist asphist.



Get Source Position (dmlist)

The source position is required as one of the inputs to mkgarf. This information can be easily obtained from the PHA2 file with dmlist:

unix% dmlist "hrcf01801N003_pha2.fits[SPECTRUM][cols x,y]" opt=data rows=1
 
 
--------------------------------------------------------------------------------
Data for Table Block SPECTRUM
--------------------------------------------------------------------------------
 
ROW    X            Y           
 
     1     16511.480468750     16367.2802734375

The source in this example is located at (16511.480468750, 16367.2802734375).



Run mkgarf

Now we have all the information needed to run mkgarf. We will have to run the tool twice, once for each row in the PHA file:

A. For row 1, LEG, order = -1

unix% punlearn mkgarf
unix% pset mkgarf outfile=1801_-1_LEG_garf.fits
unix% pset mkgarf order=-1
unix% pset mkgarf asphistfile="asphist.fits[ASPHIST]"
unix% pset mkgarf engrid="grid(rmf.fits[cols ENERG_LO,ENERG_HI])"
unix% pset mkgarf detsubsys=HRC-I grating_arm=LEG 
unix% pset mkgarf sourcepixelx=16511.480468750 sourcepixely=16367.2802734375
unix% mkgarf
Aspect Histogram File (include extension) (asphist.fits[ASPHIST]): 
Output File Name (1801_-1_LEG_garf.fits): 
Enter Grating order (-1): 
Source X Pixel (16511.48046875): 
Source Y Pixel (16367.2802734375): 
Energy grid spec (grid(rmf.fits[cols ENERG_LO,ENERG_HI])): 
Name of fits file with obs info (include extension))asphistfile -> asphist.fits[ASPHIST]): 
NONE or Name of fits file with order sorting info (NONE): 
Detector Name (HRC-I): 
Enter Grating Arm (HEG|MEG|LEG) (LEG): 
NONE, or name of ACIS window mask file (NONE): 


B. For row 2, LEG, order = 1

unix% pset mkgarf order=1
unix% pset mkgarf outfile=1801_1_LEG_garf.fits
unix% mkgarf
Aspect Histogram File (include extension) (asphist.fits[ASPHIST]): 
Output File Name (1801_1_LEG_garf.fits): 
Enter Grating order (1): 
Source X Pixel (16511.48046875): 
Source Y Pixel (16367.2802734375): 
Energy grid spec (grid(rmf.fits[cols ENERG_LO,ENERG_HI])): 
Name of fits file with obs info (include extension))asphistfile -> asphist.fits[ASPHIST]): 
NONE or Name of fits file with order sorting info (NONE): 
Detector Name (HRC-I): 
Enter Grating Arm (HEG|MEG|LEG) (LEG): 
NONE, or name of ACIS window mask file (NONE): 

The content of the parameter file may be checked using plist mkgarf.




Summary

The thread is now complete; the grating ARFs for this dataset are 1801_-1_LEG_garf.fits and 1801_1_LEG_garf.fits. Since this source is at the aimpoint/on-axis, the two garfs are nearly identical; this plot [Link to Image 2: The +1 order plotted over the -1 order] shows the +1 order plotted on top of the -1 order. This is normal and is due to the fact that the detector is symmetric, flat, and has no holes or filter boundaries. Also, the HRC-I QEU file is fairly uniform. Off-axis observations will not have such a high degree of similarity between the -1 and +1 orders.




Parameters for /home/username/cxcds_param/asphist.par


#--------------------------------------------------------------------------
#
#       Parameter file for the ASPECT HISTOGRAM Tool
#
#--------------------------------------------------------------------------
        infile = pcadf082337011N002_asol1.fits Aspect Solution List Files
       outfile = asphist.fits     Aspect Histogram Output File
       evtfile = hrcf01801N002_evt2.fits[chip_id=0] Event List Files
       dtffile = hrcf01801_000N002_dtf1.fits Live Time Correction List Files for HRC
      (geompar = geom)            Parameter file for Pixlib Geometry files
       (res_xy = 0.5)             Aspect Resolution x and y in arcsec
     (res_roll = 600.)            Aspect Resolution roll in arcsec
      (max_bin = 10000.)          Maximal number of bins
      (clobber = no)              Clobber output
      (verbose = 0)               Verbose
         (mode = ql)              
    


Parameters for /home/username/cxcds_param/mkgarf.par


   asphistfile = asphist.fits[ASPHIST] Aspect Histogram File (include extension)
       outfile = 1801_1_LEG_garf.fits Output File Name
         order = 1                Enter Grating order
  sourcepixelx = 16511.48046875   Source X Pixel
  sourcepixely = 16367.2802734375 Source Y Pixel
        engrid = grid(rmf.fits[cols ENERG_LO,ENERG_HI]) Energy grid spec
       obsfile = )asphistfile -> asphist.fits[ASPHIST] Name of fits file with obs info (include extension)
#engrid,f,a,"0.3:10:0.1",,,"Energy grid spec"
#engrid,f,a,"grid(rmf.fits[cols ENERG_LO,ENERG_HI])",,,"Energy grid spec"
      osipfile = NONE             NONE or Name of fits file with order sorting info
      maskfile = NONE             NONE, or name of ACIS window mask file
     detsubsys = HRC-I            Detector Name
   grating_arm = LEG              Enter Grating Arm
       (mirror = hrma)            Mirror Name
      (pbkfile = NONE)            NONE, or the name of the parameter block file
       (dafile = NONE)            NONE, CALDB, or name of ACIS dead-area calibra(ardlibparfile = ardlib.par)      name of ardlib parameter file
      (geompar = geom)            Parameter file for Pixlib Geometry files
      (verbose = 0)               Verbosity
      (clobber = no)              Overwrite existing files?
         (mode = ql)              Enter mode for parameter file.
    

History

22 Dec 2004 updated for CIAO 3.2: minor changes to parameter files; canned gARFs are no longer available in the CALDB, removed "Choosing an RMF" section
20 Jun 2005 CIAO 3.2.2 patch: change to asphist parameter file
06 Dec 2005 updated for CIAO 3.3: new asphist tool syntax (the GTI filter is associated with the event file instead of the aspect solution file)
01 Dec 2006 updated for CIAO 3.4: CIAO version in warning; ChIPS version; parameter file updates for mkgarf

Return to Threads Page: Top | All | Grating
Hardcopy (PDF): A4 | Letter
Last modified: 1 Dec 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.