Support #1372
The units of FileFunction
Status: | New | Start date: | 12/03/2014 | |
---|---|---|---|---|
Priority: | Normal | Due date: | ||
Assigned To: | - | % Done: | 0% | |
Category: | - | |||
Target version: | - | |||
Duration: |
Description
In
http://gammalib.sourceforge.net/user_manual/modules/model.html,
The units of FileFunction is described as
“The flux values are assumed to cm?2s?1MeV?1 (the only exception being a model for which the spatial component is a constant diffuse model GModelSpatialDiffuseConst; in this case, the units are cm?2s?1MeV?1sr?1). ”.
But it seems to be cm?2s?1MeV?1sr?1 for the other spatial models like
<source name="Background" type="RadialAcceptance" instrument="CTA">
<spectrum type="FileFunction" file="./bkg_IFAE_2A_Aar_merged_50h.txt">
<parameter scale="1.0" name="Normalization" min="0.0" max="1000.0" value="1.0" free="1"/>
</spectrum>
<radialModel type="Gaussian">
<parameter name="Sigma" scale="1.0" value="3.0" min="0.01" max="10.0" free="1"/>
</radialModel>
</source>
</source_library>
.
Is it correct? I used gammalib-00-08-01 and ctools-00-07-01.
Recurrence
No recurrence.
History
#1 Updated by Katagiri Hideaki about 10 years ago
In
http://gammalib.sourceforge.net/user_manual/modules/model.html,
The units of FileFunction is described as
“The flux values are assumed to cm?2s?1MeV?1 (the only exception being a model for which the spatial component is a constant diffuse model GModelSpatialDiffuseConst; in this case, the units are cm?2s?1MeV?1sr?1). ”.
But it seems to be cm?2s?1MeV?1sr?1 for the other spatial models like Gauss spatial function.
Is it correct? I used gammalib-00-08-01 and ctools-00-07-01.
#2 Updated by Mayer Michael about 10 years ago
The case you describe is a GCTAModelRadialAcceptance
, which represents a Gaussian describing the background in detector coordinates, NOT a Gaussian source model. This class loads a GCTABackgroundPerfTable
as spectral component. The latter holds the background rate as function of reconstructed energy per unit time, solid angle and energy. Accordingly, the unit is ph/MeV/s/sr (without the cm2), since you do not fold in gamma-ray effective areas. Jürgen, please correct me if I am wrong.
#3 Updated by Katagiri Hideaki about 10 years ago
Mayer Michael wrote:
The case you describe is a
GCTAModelRadialAcceptance
, which represents a Gaussian describing the background in detector coordinates, NOT a Gaussian source model. This class loads aGCTABackgroundPerfTable
as spectral component. The latter holds the background rate as function of reconstructed energy per unit time, solid angle and energy. Accordingly, the unit is ph/MeV/s/sr (without the cm2), since you do not fold in gamma-ray effective areas. Jürgen, please correct me if I am wrong.
Thanks for quick reply, Mayer.
I still do not understand well the latter half of what you said.
GCTABackgroundPerfTable
as spectral component. The latter holds the background rate as function of reconstructed energy per unit time, solid angle and energy. Accordingly, the unit is ph/MeV/s/sr (without the cm2), since you do not fold in gamma-ray effective areas.
I guess the effective area for background events is estimated from an IRF in ctools.
source name=“Background” type=“RadialAcceptance” instrument=“CTA”
spectrum type=“FileFunction” file="./bkg_IFAE_2A_Aar_merged_50h.txt”
The background file for “FileFunction” is something like:
15848.9327325 0.249593011513
25118.8653986 0.452675779426
39810.7184603 0.298693634921
63095.7361799 0.0841883615849
100000.001961 0.0533030141372
158489.321111 0.0114929407647
...
I want to know the units of the second column because I want to compare the charged background events with the contribution from the Galactic emission. If the unit here is ph/MeV/s/sr/cm^2, probably the effective area is taken into account for these values and I believe they can be directly compared with the intensity of the Galactic emission.
But if it is ph/MeV/s/sr, I think the values should be convoluted by the IRF for the charged background.
So it seems to me that I have to simulate the emission from both the charged background component and the Galactic emission
in order to compare them with each other.
#4 Updated by Mayer Michael about 10 years ago
Sorry that my answer was a bit confusing I now see your point.
I guess the effective area for background events is estimated from an IRF in ctools.
Actually no. To my knowledge there is no such thing as an effective area for gamma-like background events. The background we face is purely instrumental and reconstructed energies and directions are not really meaningful as we are trying to reconstruct gamma-rays. In gammalib, the background is given by a spatial shape in detector coordinates (in your case a normalised Gaussian centred on the camera center). The energy dependence can be given as the file function you provided (the GCTABackgroundPerfTable
is something different, I apologise for the confusion). Any background for CTA in gammalib is given as a count rate in units of ph/s/MeV/sr, which should be the unit in your file. Accordingly, for every event, we compute the likelihood that it originates from the given background model.
If the file function is however used for astrophysical sources, then you would need to provide an intrinsic flux in the second column ([ph/cm2/s/MeV], or [ph/cm2/s/MeV/sr] in case of a diffuse source).
I want to know the units of the second column because I want to compare the charged background events with the contribution from the Galactic emission. If the unit here is ph/MeV/s/sr/cm^2, probably the effective area is taken into account for these values and I believe they can be directly compared with the intensity of the Galactic emission.
But if it is ph/MeV/s/sr, I think the values should be convoluted by the IRF for the charged background. So it seems to me that I have to simulate the emission from both the charged background component and the Galactic emission in order to compare them with each other.
If I understand correctly, I think for this purpose you would need to either produce IRFs for the charged background (which is probably a major effort), or you use the npred
-functions of the models. To explain the latter a bit more: You can retrieve the number of expected counts from each individual model by calling the npred
function, which returns an absolute number of counts given a certain observation. If you want to compare the rate you could compare the npred
values of the galactic diffuse emission and the cosmic ray background.