We generate new pha files using batgse2dph and batbinevt, because batgse2dph calculates the energy scale exactly the same way bateconvert does, so the results will be closer to the actual data that will be coming through the ground processing pipeline. The pha files that we have already fit were generated by a different set of tools (full_rebin and sum_spectra) that assigned the energy in a slightly different way. Then, we re-fit these new pha files for coarse grid runs and far field runs so that we can update the mutau function parameters (stored in swbparams***.fits in CALDB) to be used by batdrmgen.
Derek's note:
One thing that is interesting is that the peaks in the new summed pha
files are systematically off by a tiny amount (slightly too high at lower
energies and slightly too low at higher energies). I noticed while I was
investigating the energy scaling problem that if voltage is expressed as a
quadratic function of channel, the assigned energy has a greater
systematic difference from the true energy than when channel is expressed
as a quadratic function of voltage. bateconvert (and batgse2dph) uses a
voltage=f(channel) equation to assign energy, whereas full_rebin used a
channel=f(voltage) equation. So the full_rebin-generated files have a
slightly better energy assignment. It would probably take a fairly major
software change to alter the batbinevt algorithm, so I'm inclined to just
accept the systematic discrepancy in the counts spectrum (which is less
than 0.5 keV) and correct for it in batdrmgen instead (in the form of new
fit parameters).
Details
Details