星期二, 九月 08, 2009

如何处理Fermi LAT的数据


主要参考这里. 经过自己操作, 在变成中文, 方便以后参考. 下面以090510为例.

1. 获取数据
输入至少时间和地点, 就是第一项的position, 和date.
eg. 地点: 333.400, -26.767 时间: 263607783, 263608783 (这里选择1000s, 也可以选其它的时间). 如下图

下面这个保持原样
而这些数据应该到GCN上去找. 或者在LAT的catalog上.

1.2 然后点"start search", 下载两个fits文件. 一个数据, 包含PH字样, 一个仪器数据, 包含SC字样.
比如: L090905073938E0D2F37E30_PH00.fits L090905073938E0D2F37E30_SC00.fits


2. 重新生成数据文件 (刚才获取的文件是一段比较长时间的数据), bin并且生成response文件. 命令行用红色标出了.
~/Desktop/gbm-data/lat/090510$ gtselect
(要加选项 evclsmin=1 evclsmax=3, 说明在此)
Input FT1 file[L090907111446E0D2F37E46_PH00.fits] L090905073938E0D2F37E30_PH00.fits
Output FT1 file[GRB090902B_PH.fits] GRB090510_PH.fits
RA for new search center (degrees) (0:360) [265] 333.4
Dec for new search center (degrees) (-90:90) [27.33] -26.767
radius of new search region (degrees) (0:180) [10]
start time (MET in s) (0:) [273582310] 263607783
end time (MET in s) (0:) [273582335] 263607813
lower energy limit (MeV) (0:) [100]
upper energy limit (MeV) (0:) [300000]
maximum zenith angle value (degrees) (0:180) [105]
Done.
~/Desktop/gbm-data/lat/090510$ gtbin
This is gtbin version ScienceTools-v9r15p2-fssc-20090808
Type of output file (CCUBE|CMAP|LC|PHA1|PHA2) [PHA1]
Event data file name[GRB090902B_PH.fits] GRB090510_PH.fits
Output file name[GRB090902B_PH.pha] GRB090510_PH.pha
Spacecraft data file name[L090907111446E0D2F37E46_SC00.fits] L090905073938E0D2F37E30_SC00.fits
Algorithm for defining energy bins (FILE|LIN|LOG) [LOG]
Start value for first energy bin in MeV[100]
Stop value for last energy bin in MeV[300000]
Number of logarithmically uniform energy bins[100] 30
~/Desktop/gbm-data/lat/090510$ gtrspgen
This is gtrspgen version ScienceTools-v9r15p2-fssc-20090808
Response calculation method (GRB|PS) [GRB]
Spectrum file name[GRB090510_PH.pha]
Spacecraft data file name[L090905073938E0D2F37E30_SC00.fits]
Output file name[GRB090510_PH.rsp]
Time of GRB (s)[263607783]
Response function to use, Handoff|DC2|DC2A|DC2FA|DC2BA|DC2FB etc[P6_V1_DIFFUSE]
Algorithm for defining true energy bins (FILE|LIN|LOG) [LOG]
Start value for first energy bin in MeV[30] 100
Stop value for last energy bin in MeV[300000]
Number of logarithmically uniform energy bins[100] 30

注意上面如果不输入就表示默认[]中的值, 这个值是程序记住了上次输入的. 这样很有利于一直处理同一个暴, 很多内容就直接回车就可以了.

3. 用xspec拟合谱
~/Desktop/gbm-data/lat/090510$ xspec

XSPEC version: 12.5.0ac
Build Date/Time: Thu Apr 2 03:38:12 2009

XSPEC12>data GRB090510_PH.pha
***Warning: No TLMIN keyword value for response matrix FCHAN column.
Will assume TLMIN = 1.

1 spectrum in use
Spectral Data File: GRB090510_PH.pha Spectrum 1
Net count rate (cts/s) for Spectrum:1 2.488e+00 +/- 3.436e-01
Assigned to Data Group 1 and Plot Group 1
Noticed Channels: 1-30
Telescope: GLAST Instrument: LAT Channel Type: PI
Exposure Time: 27.73 sec
Using Response (RMF) File GRB090510_PH.rsp for Source 1

XSPEC12>response GRB090510_PH.rsp
Response successfully loaded.
XSPEC12>model powerlaw (此处可发挥)

Input parameter value, delta, min, bot, top, and max values for ...
1 0.01 -3 -2 9 10
1:powerlaw:PhoIndex>
1 0.01 0 0 1e+24 1e+24
2:powerlaw:norm>

========================================================================
Model powerlaw<1> Source No.: 1 Active/On
Model Model Component Parameter Unit Value
par comp
1 1 powerlaw PhoIndex 1.00000 +/- 0.0
2 1 powerlaw norm 1.00000 +/- 0.0
________________________________________________________________________


Chi-Squared = 8.416990e+10 using 30 PHA bins.
Reduced chi-squared = 3.006068e+09 for 28 degrees of freedom
Null hypothesis probability = 0.000000e+00
Current data and model not fit yet.
XSPEC12>fit 100

Chi-Squared Lvl Par # 1 2
56.7827 -1 1.05836 1.68733e-05
......
17.4616 -2 1.87492 8.42061
==============================
Variances and Principal Axes
1 2
1.3453E-04| -0.9999 0.0140
9.8143E+01| -0.0140 -0.9999
------------------------------

========================
Covariance Matrix
1 2
1.930e-02 1.372e+00
1.372e+00 9.812e+01
------------------------

========================================================================
Model powerlaw<1> Source No.: 1 Active/On
Model Model Component Parameter Unit Value
par comp
1 1 powerlaw PhoIndex 1.87492 +/- 0.138941
2 1 powerlaw norm 8.42061 +/- 9.90575
________________________________________________________________________


Chi-Squared = 17.46 using 30 PHA bins.
Reduced chi-squared = 0.6236 for 28 degrees of freedom
Null hypothesis probability = 9.389053e-01
XSPEC12>cpd /xw
XSPEC12>plot ufspec

上面PhoIndex=1.87492就是我们想要的. 图像结果如下



1 条评论:

Y. C. Zou 说...

补充一下:
LAT的数据要得到的话,需要填包括位置和时间的两个信息,这两个对伽马暴来说得到GCN上去看他们发布的结果。