Skip to content
Gamma-ray Burst Afterglow Light Curve Fitting Tool
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
JetFit
Example_Fitter.py
GW170817.csv
README.md
Table.h5
package_list.txt

README.md

JetFit

Gamma-ray Burst Afterglow Light Curve Fitting Tool.

The JetFit package fits GRB afterglow light curves for arbitrary viewing angle using the "boosted fireball" structured jet model Duffell & MacFadyen (2013) for the jet dynamics (for details see Wu & MacFadyen (2018). The light curve computation is based on the ScaleFit package (Ryan, van Eerten, MacFadyen & Zhang (2015)). JetFit is currently in some state between alpha and beta.

Table.h5 contains the characteristic spectral functions, which are used to generate synthetic light curves. The table is almost the same as the table used in Wu & MacFadyen (2018). We are improving the table by increasing resolution, adding synchrotron absorption and wind circumburst medium. Hopefully, it will come out pretty soon.

Installation

Anaconda is recommened to be installed. The detailed python package list can be found in package_list.txt. To set up the virtual environment, run command conda create --name JetFit --file package_list.txt in terminal. Then, run conda activate JetFit to activate the environment.

Usage

To fit the light curve from GW170817, run python Example_Fitter.py.

Module Description

JetFit package consists of three classes: Interpolator, FluxGenerator and Fitter. FluxGenerator can be used separately.

InterpolatorClass:

  • _LoadTable: load characteristic spectral function table.
  • _SetScale: set scales for the table. By default, f_peak and tau are in log scale.
  • _GetInterpolator: use scipy.interpolate.RegularGridInterpolator as interpolator.
  • GetValue: get values for characteristic spectral function at specific position (tau, Eta0, GammaB, theta_obs).

FluxGeneratorClass:

  • GetTaus: rescale the observational time in second.
  • GetTransformedValue: get the transformed values F_peak, nu_c and nu_m (Ryan et al. 2015).
  • GetSpectral: calculate synthetic light curves F_nu (Sari et al. 1998).
  • GetIntegratedFlux: calculate synthetic integrated light curves.

ScaleFitClass:

  • _SetFitParameter: set up ScaleFit, e.g. parameter scales and parameter bounds.
  • LoadData: load observational data.
  • GetSampler: initialize sampler from emcee package.
  • BurnIn: burn in and prepare for sampling.
  • RunSampler: run sampling procedure and save results to local drive.
You can’t perform that action at this time.