Basic Lightcurves
![[CXC Logo]](../../imgs/cxc-logo.gif)
CIAO 4.0 Science Threads
OverviewLast Update: 23 Jan 2008 - updated for CIAO 4.0: updated ChIPS syntax; lightcurve tool no longer in CIAO; removed "Tool: dmextract vs. lightcurve" section; filenames, screen output, and region files updated for reprocessed data (version N003 event file for 953) Synopsis: The CIAO tool dmextract accurately applies good time interval (GTI) information when creating lightcurves. Its predecessor, lightcurve, was removed from CIAO at version 4.0. Purpose: To create lightcurves for use in a variety of analyses. Related Links:
|
Contents
- Get Started
- ACIS Lightcurves
- HRC Lightcurves
- Caveats
- Parameter files:
- History
- Images
Get Started
Sample ObsIDs used: 953 (ACIS-I, 47 Tuc); 461 (HRC-I, 3C 273)
File types needed: evt2; dtf1 (ObsID 461 only)
ACIS Lightcurves
The most common lightcurve is made from a point source observed with the ACIS detector. This may be done to get an idea of the variability of the source or to help identify periods of high background.
To begin, we define the regions - two source and one
background - which will be used to create the
lightcurves. For instructions on how to create regions in
ds9, see the Using
CIAO Region Files thread. The regions used here
are shown in Figure 1
:
unix% more src1.reg # Region file format: CIAO version 1.0 circle(4010.5,4037.5,8) unix% more src2.reg # Region file format: CIAO version 1.0 circle(4035.5,4034.5,8) unix% more bkg.reg # Region file format: CIAO version 1.0 circle(3875.5,3972,54.5)
Determine which chips are being used
dmextract uses a ccd_id filter on the input file ensure that the proper GTIs are used. Use dmstat to determine the correct chip:
unix% punlearn dmstat
unix% dmstat "acisf00953N003_evt2.fits[sky=region(src1.reg)][cols ccd_id]"
ccd_id
min: 3 @: 1
max: 3 @: 1
mean: 3
sigma: 0
sum: 7284
good: 2428
null: 0
unix% dmstat "acisf00953N003_evt2.fits[sky=region(src2.reg)][cols ccd_id]"
ccd_id
min: 3 @: 1
max: 3 @: 1
mean: 3
sigma: 0
sum: 5850
good: 1950
null: 0
unix% dmstat "acisf00953N003_evt2.fits[sky=region(bkg.reg)][cols ccd_id]"
ccd_id
min: 3 @: 1
max: 3 @: 1
mean: 3
sigma: 0
sum: 663
good: 221
null: 0
The regions with which we are working are all located on chip 3 (ACIS-I3); see Figure 6.1 of the POG for an illustration of the focal plane)
Create a background-subtracted lightcurve
First we extract a background-subtracted lightcurve for "src2":
unix% punlearn dmextract unix% pset dmextract \ infile="acisf00953N003_evt2.fits[ccd_id=3,sky=region(src2.reg)][bin time=::2000]" unix% pset dmextract outfile="src2_sub_lc.fits" unix% pset dmextract bkg="acisf00953N003_evt2.fits[ccd_id=3,sky=region(bkg.reg)]" unix% pset dmextract opt="ltc1" unix% dmextract Input event file (acisf00953N003_evt2.fits[ccd_id=3,sky=region(src2.reg)][bin time=::2000]): Enter output file name (src2_sub_lc.fits):
You can check the parameter file that was used with plist dmextract.
The lightcurve may be plotted using ChIPS (Note that this example uses the Python interface to ChIPS):
unix% chips chips> make_figure("src2_sub_lc.fits[cols time,net_rate,err_rate]", "line.color=red")
This lightcurve is shown in Figure
2
. There is a significant drop in count rate near
6.9610x107 seconds. This information is used
again in the next
section. Quit ChIPS before continuing:
chips> quit
Examining the lightcurve with dmlist shows the same results:
unix% dmlist "src2_sub_lc.fits[cols time,count_rate]" data
--------------------------------------------------------------------------------
Data for Table Block LIGHTCURVE
--------------------------------------------------------------------------------
ROW TIME COUNT_RATE
1 69584184.1139039993 0.09905969738988
2 69586184.1139039993 0.08507730
3 69588184.1139039993 0.0739362250
4 69590184.1139039993 0.0840644750
5 69592184.1139039993 0.06482080
6 69594184.1139039993 0.058743850
7 69596184.1139039993 0.062795150
8 69598184.1139039993 0.06532721250
9 69600184.1139039993 0.07545546250
10 69602184.1139039993 0.06634003750
11 69604184.1139039993 0.0840644750
12 69606184.1139039993 0.0719105750
13 69608184.1139039993 0.04000658750
14 69610184.1139039993 0.0010128250
15 69612184.1139039993 0.050641250
16 69614184.1139039993 0.04861560
17 69616184.1139039993 0.04085938928173
Looking for variability
It is also valuable to compare the lightcurves of sources in the same field when looking for variation. Here we extract a lightcurve for each of the "src1" and "src2" regions (intentionally including the background counts):
unix% punlearn dmextract
unix% dmextract outfile="curve_1.fits" opt="ltc1" \
infile="acisf00953N003_evt2.fits[ccd_id=3,sky=region(src1.reg)][bin time=::2000]"
unix% dmextract outfile="curve_2.fits" opt="ltc1" \
infile="acisf00953N003_evt2.fits[ccd_id=3,sky=region(src2.reg)][bin time=::2000]"
The lightcurves can be plotted in ChIPS:
unix% chips chips> split(2, 1, 0.01) chips> make_figure("curve_1.fits[cols time,count_rate]") chips> current_plot("plot2") chips> make_figure("curve_2.fits[cols time,count_rate]")
These commands produce Figure
3
.
The results can also be examined with dmlist:
unix% dmlist "curve_1.fits[cols time,count_rate]" data
...
13 69608184.1139039993 0.07241698750
14 69610184.1139039993 0.07444263750
15 69612184.1139039993 0.06937851250
16 69614184.1139039993 0.08355806250
17 69616184.1139039993 0.06891210431098
unix% dmlist "curve_2.fits[cols time,count_rate]" data
...
13 69608184.1139039993 0.04000658750
14 69610184.1139039993 0.0010128250
15 69612184.1139039993 0.050641250
16 69614184.1139039993 0.04861560
17 69616184.1139039993 0.04085938928173
Comparing this to the lightcurve data from the previous section proves two things:
-
This is not an intrumental effect, since it shows up in curve_2.fits but not curve_1.fits. An instrumental feature would appear in both sources, as they are close together, on the same chip, etc.
-
This is not a background feature, since it is present in both the subtracted (src2_sub_lc.fits) and unsubtracted (curve_2.fits) lightcurves.
It is highly likely, therefore, that the dip in count rate is an indication of a variable star. In the case of 47 Tuc, this is due to a binary system; see the Chandra Photo Album entry for 47 Tucanae for more information.
High background levels
The technique for identifying periods of high background from a lightcurve - and subsequently filtering them out - is explained in detail in the Filtering Lightcurves thread.
HRC Lightcurves
The proper method of creating an HRC lightcurve requires accounting for the Dead Time Factor (DTF). The DTF describes the detector's deviation from the standard detection efficiency. This time-dependent change is due to the physical effect of an event striking the micro-channel plate, as illustrated in the MCP Principles page. The DTF is evaluated roughly every 2 seconds and the data are stored in the "dtf1.fits" file. The average DTF value within the time bin is used by dmextract to correct the exposure time and count rate in the lightcurve.
The source region for this example has been saved in the file hrc_src.reg. Again, for instructions on how to create regions in ds9, see the Using CIAO Region Files thread.
unix% more hrc_src.reg # Region file format: CIAO version 1.0 circle(16478,16292,19.5) unix% punlearn dmextract unix% pset dmextract infile="hrcf00461N003_evt2.fits[sky=region(hrc_src.reg)][bin time=64938947.367:64959159.548:1000]" unix% pset dmextract outfile=hrc_lc.fits unix% pset dmextract opt=ltc1 unix% pset dmextract exp=hrcf00461_001N003_dtf1.fits unix% dmextract Input event file (hrcf00461N003_evt2.fits[sky=region(hrc_src.reg)][bin time=64938947.367:64959159.548:1000]): Enter output file name (hrc_lc.fits):
You can check the parameter file that was used with plist dmextract.
Plotting the lightcurve in ChIPS:
unix% chips chips> make_figure("hrc_lc.fits[cols time,count_rate]") chips> limits(Y_AXIS, 10.7, AUTO)
creates Figure 4
.
Examine the lightcurve with dmlist:
unix% dmlist "hrc_lc.fits[cols time,count_rate]" data
--------------------------------------------------------------------------------
Data for Table Block LIGHTCURVE
--------------------------------------------------------------------------------
ROW TIME COUNT_RATE
1 64939447.3669999987 11.0370718045
2 64940447.3669999987 11.1034571494
3 64941447.3669999987 11.0080340468
4 64942447.3669999987 10.7977612541
5 64943447.3669999987 10.9829147666
6 64944447.3669999987 10.8403845035
7 64945447.3669999987 11.1324409057
8 64946447.3669999987 10.9762097416
9 64947447.3669999987 11.0741103068
10 64948447.3669999987 11.0283615145
11 64949447.3669999987 10.8690184268
12 64950447.3669999987 10.8724532421
13 64951447.3669999987 11.0687810980
14 64952447.3669999987 10.8811205972
15 64953447.3669999987 10.9841560313
16 64954447.3669999987 10.9578789351
17 64955447.3669999987 11.0886790730
18 64956447.3669999987 10.9611792524
19 64957447.3669999987 11.1768313479
20 64958447.3669999987 11.0863053714
21 64959447.3669999987 0.52092756248201
Refer to the Filtering Lightcurves thread for information on how to handle the low point at ~6.4959E+07 seconds.
Caveats
There are a number of subtleties that it is important to be aware of when using lightcurves for timing analysis. These issues are described in the Timing Analysis with Lightcurves why topic; please read that document before continuing with the analysis.
Parameters for /home/username/cxcds_param/dmextract.par
#--------------------------------------------------------------------
#
# DMEXTRACT -- extract columns or counts from an event list
#
#--------------------------------------------------------------------
infile = acisf00953N003_evt2.fits[ccd_id=3,sky=region(src2.reg)][bin time=::2000] Input event file
outfile = src2_sub_lc.fits Enter output file name
(bkg = acisf00953N003_evt2.fits[ccd_id=3,sky=region(bkg.reg)]) Background
region file or fixed background (counts/pixel/s) subtraction
(error = gaussian) Method for error determination(poisson|gaussian|<variance file>)
(bkgerror = gaussian) Method for background error determination(poisson|gaussian|<variance file>)
(bkgnorm = 1.0) Background normalization
(exp = ) Exposure map image file
(bkgexp = ) Background exposure map image file
(sys_err = 0) Fixed systematic error value for SYS_ERR keyword
(opt = ltc1) Output file type: pha1
(defaults = ${ASCDS_CALIB}/cxo.mdb -> /soft/ciao/data/cxo.mdb) Instrument defaults file
(wmap = ) WMAP filter/binning (e.g. det=8 or default)
(clobber = no) OK to overwrite existing output file(s)?
(verbose = 0) Verbosity level
(mode = ql)
|
Parameters for /home/username/cxcds_param/dmextract.par
#--------------------------------------------------------------------
#
# DMEXTRACT -- extract columns or counts from an event list
#
#--------------------------------------------------------------------
infile = hrcf00461N003_evt2.fits[sky=region(hrc_src.reg)][bin time=64938947.367:64959159.548:1000] Input event file
outfile = hrc_lc.fits Enter output file name
(bkg = ) Background region file or fixed background (counts/pixel/s) subtraction
(error = gaussian) Method for error determination(poisson|gaussian|<variance file>)
(bkgerror = gaussian) Method for background error determination(poisson|gaussian|<variance file>)
(bkgnorm = 1.0) Background normalization
(exp = hrcf00461_001N003_dtf1.fits) Exposure map image file
(bkgexp = ) Background exposure map image file
(sys_err = 0) Fixed systematic error value for SYS_ERR keyword
(opt = ltc1) Output file type
(defaults = ${ASCDS_CALIB}/cxo.mdb -> /soft/ciao/data/cxo.mdb) Instrument defaults file
(wmap = ) WMAP filter/binning (e.g. det=8 or default)
(clobber = no) OK to overwrite existing output file(s)?
(verbose = 0) Verbosity level
(mode = ql)
|
History
| 03 Jan 2005 | reviewed for CIAO 3.2: no changes |
| 21 Dec 2005 | updated for CIAO 3.3: default value of dmextract error and bkgerror parameters is "gaussian"; dmextract can now accept a DTF file in the exp parameter, which simplifies the process of creating HRC Lightcurves |
| 01 Dec 2006 | updated for CIAO 3.4: CHIPS version |
| 23 Jan 2008 | updated for CIAO 4.0: updated ChIPS syntax; lightcurve tool no longer in CIAO; removed "Tool: dmextract vs. lightcurve" section; filenames, screen output, and region files updated for reprocessed data (version N003 event file for 953) |
