Jet#

class jetset.jet_model.Jet(cosmo=None, name=None, emitters_type='electrons', emitters_distribution='plc', emitters_distribution_log_values=False, beaming_expr='delta', jet_workplace=None, verbose=False, clean_work_dir=True, electron_distribution=None, proton_distribution=None, electron_distribution_log_values=None, proton_distribution_log_values=None, geometry='spherical')[source]#

Bases: JetBase

Concrete jet model for leptonic or hadronic emitter populations.

Methods Summary

add_bremss_ep_component()

Add electron-proton bremsstrahlung spectral component.

add_pp_gamma_component()

Add proton-proton gamma-ray spectral component.

add_pp_neutrino_component()

Add proton-proton neutrino spectral components.

available_electron_distributions()

Print available electron-distribution names.

available_proton_distributions()

Print available proton-distribution names.

eval_synch_pol(nu_range_obs)

Evaluate synchrotron polarization in the observer frame.

eval_synch_pol_blob(nu_range_blob)

Evaluate synchrotron polarization in the blob frame.

get_electron_distribution_name()

Return the active electron-distribution name.

get_proton_distribution_name()

Return the active proton-distribution name.

set_B_eq(nuFnu_obs, nu_obs[, B_min, B_max, ...])

Estimate equipartition magnetic field by scanning a logarithmic B grid, for a given observed flux of the synchrotron emission (nuFnu_obs) at a given observed frequency (nu_obs)

set_N_from_F_sync(F_sync)

Set normalization to match target observed integrated synchrotron flux.

set_N_from_L_sync(L_sync)

Set normalization to match target integrated synchrotron luminosity.

set_N_from_U_emitters(U[, gmin, gmax])

Set normalization to match target emitter energy density.

set_N_from_U_vol_emitters(U_vol[, gmin, gmax])

Set normalization to match target integrated emitter energy.

set_N_from_nuFnu(nuFnu_obs, nu_obs)

Set normalization to match target observed nuFnu at nu_obs.

set_N_from_nuLnu(nuLnu_src, nu_src)

Set normalization to match target source-frame nuLnu at nu_src.

show_electron_distribution()

Print electron-distribution configuration.

show_proton_distribution()

Print proton-distribution configuration.

Methods Documentation

add_bremss_ep_component()[source]#

Add electron-proton bremsstrahlung spectral component.

add_pp_gamma_component()[source]#

Add proton-proton gamma-ray spectral component.

add_pp_neutrino_component()[source]#

Add proton-proton neutrino spectral components.

static available_electron_distributions()[source]#

Print available electron-distribution names.

static available_proton_distributions()[source]#

Print available proton-distribution names.

eval_synch_pol(nu_range_obs)[source]#

Evaluate synchrotron polarization in the observer frame.

Returns:

Polarization degree and corresponding nuFnu values.

Return type:

tuple of ndarray

eval_synch_pol_blob(nu_range_blob)[source]#

Evaluate synchrotron polarization in the blob frame.

Parameters:

nu_range_blob (array-like or float) – Blob-frame frequency values in Hz. A scalar is accepted and is internally promoted to a one-dimensional array.

Returns:

  • pol_nu_blob (ndarray) – Synchrotron polarization degree evaluated at nu_range_blob.

  • nuLnu_blob (ndarray) – Synchrotron nuLnu values in the blob frame at the same frequencies.

get_electron_distribution_name()[source]#

Return the active electron-distribution name.

get_proton_distribution_name()[source]#

Return the active proton-distribution name.

set_B_eq(nuFnu_obs, nu_obs, B_min=1e-09, B_max=1.0, N_pts=20, plot=False)[source]#

Estimate equipartition magnetic field by scanning a logarithmic B grid, for a given observed flux of the synchrotron emission (nuFnu_obs) at a given observed frequency (nu_obs)

Parameters:
  • nuFnu_obs (float) – Target observed differential synchrotron flux in erg cm^-2 s^-1.

  • nu_obs (float) – Observed frequency in Hz.

  • B_min (float, optional) – Scan bounds for magnetic field in Gauss.

  • B_max (float, optional) – Scan bounds for magnetic field in Gauss.

  • N_pts (int, optional) – Number of logarithmically spaced trial values.

  • plot (bool, optional) – If True, show diagnostic curves for U_e and U_B.

Returns:

(B_best, B_grid, U_B, U_e).

Return type:

tuple

set_N_from_F_sync(F_sync)[source]#

Set normalization to match target observed integrated synchrotron flux.

Parameters:

F_sync (float) – Target observed integrated synchrotron flux in erg cm^-2 s^-1.

set_N_from_L_sync(L_sync)[source]#

Set normalization to match target integrated synchrotron luminosity.

Parameters:

L_sync (float) – Target source-frame synchrotron luminosity in erg s^-1.

set_N_from_U_emitters(U, gmin=None, gmax=None)[source]#

Set normalization to match target emitter energy density.

Parameters:
  • U (float) – Target energy density in erg cm^-3.

  • gmin (float, optional) – Integration bounds in Lorentz factor used for eval_U.

  • gmax (float, optional) – Integration bounds in Lorentz factor used for eval_U.

set_N_from_U_vol_emitters(U_vol, gmin=None, gmax=None)[source]#

Set normalization to match target integrated emitter energy.

Parameters:
  • U_vol (float) – Target integrated energy in erg over emitting volume.

  • gmin (float, optional) – Integration bounds in Lorentz factor used for eval_U.

  • gmax (float, optional) – Integration bounds in Lorentz factor used for eval_U.

set_N_from_nuFnu(nuFnu_obs, nu_obs)[source]#

Set normalization to match target observed nuFnu at nu_obs.

Parameters:
  • nuFnu_obs (float) – Target observed differential flux in erg cm^-2 s^-1.

  • nu_obs (float) – Observed frequency in Hz.

set_N_from_nuLnu(nuLnu_src, nu_src)[source]#

Set normalization to match target source-frame nuLnu at nu_src.

Parameters:
  • nuLnu_src (float) – Target source-frame luminosity at nu_src in erg s^-1.

  • nu_src (float) – Source-frame frequency in Hz.

show_electron_distribution()[source]#

Print electron-distribution configuration.

show_proton_distribution()[source]#

Print proton-distribution configuration.