eppaurora

eppaurora.brems

Atmospheric bremsstrahlung ionization parametrization [1]

[1]

Berger, M.J., Seltzer, S.M., Maeda, K., Some new results on electron transport in the atmosphere, Journal of Atmospheric and Terrestrial Physics, v36, i4, pp. 591–617, April 1974, doi: 10.1016/0021-9169(74)90085-3

eppaurora.brems.berger1974(energy, flux, scale_height, rho, ens=None, zm_p_en=None, coeffs=None, fillna=None, log3=True, rbf='multiquadric')[source]

Bremsstrahlung ionization by secondary electrons

Formulae and parameters as described in [1].

By default, the log(coefficients) are interpolated wrt. log(energy) and log(zm) using scipy.interpolated.Rbf. The default “multiquadric” should work fine, if not consider using “thin-plate” splines.

Parameters:
  • energy (array_like (M, ...)) – Energy E_0 of the mono-energetic electron beam [keV]. A scalar (0-D) value is promoted to 1-D with one element.

  • flux (array_like (M,...)) – Energy flux Q_0 of the mono-energetic electron beam [keV / cm² / s¹].

  • scale_height (array_like (N, ...)) – The atmospheric scale heights [cm].

  • rho (array_like (N, ...)) – The atmospheric mass density [g / cm³].

  • ens (array_like (I,), optional) – The energies (one axis) of the coefficient array, used to interpolate the coefficients to energy. Defaults to the Berger et al., 1974 coefficients.

  • zm_p_en (array_like (J,), optional) – The atmospheric depth (the other axis) of the coefficient array, used to interpolate the coefficients to z = scale_height * rhos. Defaults to the Berger et al., 1974 coefficients.

  • coeffs (array_like, (J, I), optional) – The bremsstrahlung energy dissipation coefficients. Defaults to the Berger et al., 1974 coefficients.

  • fillna (float or None, optional (default None)) – Value to use for nan values in coeffs, None skips them.

  • log3 (bool, optional (default True)) – Interpolate the coefficients as log(ens)-log(zm)-log(coeff) instead of a linear variant.

  • rbf (str or callable, optional (default "multiquadric")) – Radial basis functions to use for scipy.interpolate.Rbf.

Returns:

a_br – A scalar (0-D) energy is promoted to 1-D, and the result will have shape (1, N), not (N,). Energy dissipation rate, units: [keV cm⁻³ s⁻¹]

Return type:

array_like (M, N)

References

eppaurora.conductivity

Atmospheric conductivity from electron densities [1] [2] [3]

[1]

A. Brekke, J. R. Doupnik, P. M. Banks, Incoherent scatter measurements of E region conductivities and currents in the auroral zone, J. Geophys. Res., 79(25), 3773–3790, Sept. 1974, doi: 10.1029/JA079i025p03773

[2]

James F. Vickrey, Richard R. Vondrak, Stephen J. Matthews, The diurnal and latitudinal variation of auroral zone ionospheric conductivity, J. Geophys. Res., 86(A1), 65–75, Jan. 1981, doi: 10.1029/JA086iA01p00065

[3]

R. M. Robinson, R. R. Vondrak, K. Miller, T. Dabbs, D. Hardy, On calculating ionospheric conductances from the flux and energy of precipitating electrons, J. Geophys. Res. Space Phys., 92(A3), 2565–2569, Mar. 1987, doi: 10.1029/JA092iA03p02565

eppaurora.conductivity.SigmaH_robinson1987(en_avg, flx)[source]

Hall conductance [2]

Directly derived from the electron mean energy and energy flux.

Parameters:
  • en_avg (float or array_like (M, ...)) – Electron average energy in [keV]

  • flx (float or array_like (M, ...)) – Energy flux [ergs cm⁻² s⁻¹].

Returns:

ΣH – Hall conductance [S].

Return type:

float or array_like (M, N) if broadcastable

References

eppaurora.conductivity.SigmaP_robinson1987(en_avg, flx)[source]

Pedersen conductance [3]

Directly derived from the electron mean energy and energy flux.

Parameters:
  • en_avg (float or array_like (M, ...)) – Electron average energy in [keV]

  • flx (float or array_like (M, ...)) – Energy flux [ergs cm⁻² s⁻¹].

Returns:

ΣP – Pedersen conductance [S].

Return type:

float or array_like (M, N) if broadcastable

References

eppaurora.conductivity.hall(ne, bmag, ion_gyro, ion_coll)[source]

Hall conductivity σH

Formulae and parameters as described in [4] [5], neglecting electron–neutral collisions.

Parameters:
  • ne (float or array_like (M, ...)) – Electron density in [m⁻³]

  • bmag (float or array_like (M,...)) – Magnitude of the magnetic B-field [T].

  • ion_gyro (float or array_like (N, ...)) – The ion gyro frequency [s⁻¹]

  • ion_coll (float or array_like (N, ...)) – The ion collision frequency [s⁻¹]

Returns:

σH – Hall conductivity [S m⁻¹].

Return type:

float or array_like (M, N) if broadcastable

References

eppaurora.conductivity.ion_coll(n_neutral)[source]

Ion–neutral collision frequency

Derived from the atmospheric neutral density [6] e.g., from NRLMSISE-00.

Parameters:

n_neutral (float or array_like (M, ...)) – Atmospheric density in [cm⁻³]

Returns:

ion_coll – Ion–neutral collision frequency [s⁻¹]

Return type:

float or array_like (M, …)

References

eppaurora.conductivity.ion_gyro(bmag, m_ion=30.0)[source]

Ion gyro (cyclotron) frequency

Parameters:
  • bmag (float or array_like (M,...)) – Magnitude of the magnetic B-field [T].

  • m_ion (float or array_like (M, ...), optional (default 30.0)) – Ion mass [GeV / c²]

Returns:

ion_gyro – Ion cyclotron frequency [s⁻¹]

Return type:

float or array_like (M, …)

eppaurora.conductivity.pedersen(ne, bmag, ion_gyro, ion_coll)[source]

Pedersen conductivity σP

Formulae and parameters as described in [7] [8], neglecting electron–neutral collisions.

Parameters:
  • ne (float or array_like (M, ...)) – Electron density in [m⁻³]

  • bmag (float or array_like (M, ...)) – Magnitude of the magnetic B-field [T].

  • ion_gyro (float or array_like (N, ...)) – The ion gyro frequency [s⁻¹]

  • ion_coll (float or array_like (N, ...)) – The ion collision frequency [s⁻¹]

Returns:

σP – Pedersen conductivity [S m⁻¹].

Return type:

float or array_like (M, N) if broadcastable

References

eppaurora.electrons

Atmospheric ionization rate parametrizations

Includes the atmospheric ionization rate parametrizations for auroral and medium-energy electron precipitation, 100 eV–1 MeV [1], [2], and [3].

[1]

Roble and Ridley, Ann. Geophys., 5A(6), 369–382, 1987

[2]

Fang et al., J. Geophys. Res., 113, A09311, 2008

[3]

Fang et al., Geophys. Res. Lett., 37, L22106, 2010

eppaurora.electrons.fang2008(energy, flux, scale_height, rho, pij=None)[source]

Atmospheric electron energy dissipation from Fang et al., 2008

Ionization profile parametrization as derived in Fang et al., 2008 [9].

Parameters:
  • energy (array_like (M,...)) – Characteristic energy E_0 [keV] of the Maxwellian distribution.

  • flux (array_like (M,...)) – Integrated energy flux Q_0 [keV / cm² / s¹]

  • scale_height (array_like (N,...)) – The atmospheric scale height(s) [cm].

  • rho (array_like (N,...)) – The atmospheric densities [g / cm³], corresponding to the scale heights.

  • pij (array_like (8, 4), optional) – Polynomial coefficents for the electron energy dissipation per atmospheric depth. Default: None (as given in the reference).

Returns:

en_diss – The dissipated energy profiles [keV].

Return type:

array_like (M,N)

References

eppaurora.electrons.fang2010_maxw_int(energy, flux, scale_height, rho, bounds=(0.1, 300.0), nstep=128, pij=None)[source]

Integrate Fang et al., 2010 over a Maxwellian spectrum

Integrates the mono-energetic parametrization from Fang et al., 2010 [10] over a Maxwellian spectrum with characteristic energy energy and total energy flux flux.

Parameters:
  • energy (float or array_like (M,...)) – Characteristic energy E_0 [keV] of the Maxwellian distribution.

  • flux (float or array_like (M,...)) – Integrated energy flux Q_0 [keV / cm² / s¹]

  • scale_height (float or array_like (N,...)) – The atmospheric scale heights [cm].

  • rho (float or array_like (N,...)) – The atmospheric mass density [g / cm³]

  • bounds (tuple, optional) – (min, max) [keV] of the integration range to integrate the Maxwellian. Make sure that this is appropriate to encompass the spectrum. Default: (0.1, 300.)

  • nsteps (int, optional) – Number of integration steps, default: 128.

  • pij (array_like (8, 4), optional) – Polynomial coefficents for the electron energy dissipation per atmospheric depth. Default: None (as given in the reference).

Returns:

en_diss – The dissipated energy profiles [keV].

Return type:

array_like (M,N)

References

See also

fang2010_mono, fang2010_specfun_int, pflux_maxwell

eppaurora.electrons.fang2010_mono(energy, flux, scale_height, rho, pij=None)[source]

Atmospheric electron energy dissipation from Fang et al., 2010

Parametrization for mono-energetic electrons [11].

Parameters:
  • energy (array_like (M,...)) – Energy E_0 of the mono-energetic electron beam [keV].

  • flux (array_like (M,...)) – Energy flux Q_0 of the mono-energetic electron beam [keV / cm² / s¹].

  • scale_height (array_like (N,...)) – The atmospheric scale heights [cm].

  • rho (array_like (N,...)) – The atmospheric mass densities [g / cm³], corresponding to the scale heights.

  • pij (array_like (8, 4), optional) – Polynomial coefficents for the electron energy dissipation per atmospheric depth. Default: None (as given in the reference).

Returns:

en_diss – The dissipated energy profiles [keV].

Return type:

array_like (M,N)

References

eppaurora.electrons.fang2010_spec_int(ens, dfluxes, scale_height, rho, pij=None, axis=-1)[source]

Integrate over a given energy spectrum

Integrates over the mono-energetic parametrization q from [12] using the given differential particle spectrum phi:

\(\int_\text{spec} \phi(E) q(E, Q) E \text{d}E\)

Parameters:
  • ens (array_like (M,...)) – Central (bin) energies of the spectrum

  • dfluxes (array_like (M,...)) – Differential particle fluxes in the given bins

  • scale_height (array_like (N,...)) – The atmospheric scale heights

  • rho (array_like (N,...)) – The atmospheric densities, corresponding to the scale heights.

  • pij (array_like (8, 4), optional) – Polynomial coefficents for the electron energy dissipation per atmospheric depth. Default: None (as given in the reference).

  • axis (int, optional) – The axis to use for integration, default: -1 (last axis).

Returns:

en_diss – The dissipated energy profiles [keV].

Return type:

array_like (N)

References

See also

fang2010_mono, ediss_spec_int

eppaurora.electrons.rr1987(energy, flux, scale_height, rho)[source]

Atmospheric electron energy dissipation Roble and Ridley, 1987 [13]

Equations (typo corrected) taken from Fang et al., 2008.

Parameters:
  • energy (array_like (M,...)) – Characteristic energy E_0 [keV] of the Maxwellian distribution.

  • flux (array_like (M,...)) – Integrated energy flux Q_0 [keV / cm² / s¹]

  • scale_height (array_like (N,...)) – The atmospheric scale heights [cm].

  • rho (array_like (N,...)) – The atmospheric mass density [g / cm³]

Returns:

en_diss – The dissipated energy profiles [keV].

Return type:

array_like (M,N)

References

eppaurora.electrons.rr1987_mod(energy, flux, scale_height, rho)[source]

Atmospheric electron energy dissipation Roble and Ridley, 1987 [14]

Equations (typo corrected) taken from Fang et al., 2008. Modified polynomial values to get closer to Fang et al., 2008, origin unknown.

Parameters:
  • energy (array_like (M,...)) – Characteristic energy E_0 [keV] of the Maxwellian distribution.

  • flux (array_like (M,...)) – Integrated energy flux Q_0 [keV / cm² / s¹]

  • scale_height (array_like (N,...)) – The atmospheric scale heights [cm].

  • rho (array_like (N,...)) – The atmospheric mass density [g / cm³]

Returns:

en_diss – The dissipated energy profiles [keV].

Return type:

array_like (M,N)

References

eppaurora.protons

Atmospheric ionization rate parametrizations

Includes the atmospheric ionization rate parametrization for auroral proton precipitation [1].

[1]

Fang, X., Lummerzheim, D., and Jackman, C. H. (2013), Proton impact ionization and a fast calculation method, J. Geophys. Res. Space Physics, 118, 5369–5378, doi:10.1002/jgra.50484.

eppaurora.protons.fang2013_protons(energy, flux, scale_height, rho, pij=None)[source]

Proton ionization parametrization by Fang et al., 2013

Parametrization for mono-energetic protons as described in [15].

Parameters:
  • energy (array_like (M,...)) – Energy E_0 of the mono-energetic proton beam [keV].

  • flux (array_like (M,...)) – Energy flux Q_0 of the mono-energetic proton beam [keV / cm² / s¹].

  • scale_height (array_like (N,...)) – The atmospheric scale heights [cm].

  • rho (array_like (N,...)) – The atmospheric mass densities [g / cm³], corresponding to the scale heights.

  • pij (array_like (12, 4), optional) – Polynomial coefficents for the proton energy dissipation per atmospheric depth. Default: None (as given in the reference).

Returns:

en_diss – The dissipated energy profiles [keV].

Return type:

array_like (M,N)

References

eppaurora.recombination

Atmospheric recombination rate parametrizations

Atmospheric recombination rate parametrizations as described in [1], [2], and [3].

[1]

Vickrey et al., J. Geophys. Res. Space Phys., 87, A7, 5184–5196, doi:10.1029/ja087ia07p05184

[2]

Gledhill, Radio Sci., 21, 3, 399-408, doi:10.1029/rs021i003p00399

eppaurora.recombination.alpha_gledhill1986_aurora(h)[source]

Gledhill 1986, Aurora parameterization [16]

Parameters:

h (float or array_like) – Altitude in [km]

Returns:

alpha – The recombination rate [cm³ s⁻¹].

Return type:

float or array_like

References

eppaurora.recombination.alpha_gledhill1986_day(h)[source]

Gledhill 1986, day-time parameterization [17]

Parameters:

h (float or array_like) – Altitude in [km]

Returns:

alpha – The recombination rate [cm³ s⁻¹].

Return type:

float or array_like

References

eppaurora.recombination.alpha_gledhill1986_night(h)[source]

Gledhill 1986, night-time parameterization [18]

Parameters:

h (float or array_like) – Altitude in [km]

Returns:

alpha – The recombination rate [cm³ s⁻¹].

Return type:

float or array_like

References

eppaurora.recombination.alpha_ssusi(z, alpha0=4.2e-07, scaleh=28.9, z0=108.0, z1=None)[source]

Recombination rate from the SSUSI algorithm [19]

Implements section 2.6.2.15 from [20], more details are also in [21].

Parameters:
  • z (float, array_like) – Profile altitude [km].

  • alpha0 (float, optional) – Predetermined peak effective recombination coefficient. Default: 4.2e-7

  • scaleh (float, optional) – Predetermined scale height [km] of the effective recombination coefficient. Default: 28.9.

  • z0 (float, optional) – Predetermined altitude [km] of the peak effective recombination coefficient. Default: 108.

  • z1 (float, optional) – Use alpha_vickrey1982() above z1 [km]. Default: None

Returns:

alpha – The recombination rate [cm³ s⁻¹].

Return type:

float or array_like

References

eppaurora.recombination.alpha_vickrey1982(h)[source]

Vickrey et al. 1982 [22]

Parameters:

h (float or array_like) – Altitude in [km]

Returns:

alpha – The recombination rate [cm³ s⁻¹].

Return type:

float or array_like

References

eppaurora.spectra

Particle precipitation spectra

Includes variants describing a normalized particle flux, as well as variants describing a normalized energy flux.

eppaurora.spectra.ediss_spec_int(ens, dfluxes, scale_height, rho, func, axis=-1, func_kws=None)[source]

Integrate over a given energy spectrum

Integrates a mono-energetic parametrization q, e.g. from Fang et al., 2010 using the given differential particle spectrum phi:

\(\int_\text{spec} \phi(E) q(E, Q) E \text{d}E\)

This function uses the differential spectrum evaluated at the given energy bins.

Parameters:
  • ens (array_like (M,...)) – Central (bin) energies of the spectrum

  • dfluxes (array_like (M,...)) – Differential particle fluxes in the given bins

  • scale_height (array_like (N,...)) – The atmospheric scale heights

  • rho (array_like (N,...)) – The atmospheric densities, corresponding to the scale heights.

  • func (callable) – Mono-energetic energy dissipation function to integrate.

  • axis (int, optional) – The axis to use for integration, default: -1 (last axis).

  • func_kws (dict-like, optional) – Optional keyword arguments to pass to the mono-energetic energy dissipation function. Default: None

Returns:

en_diss – The dissipated energy profiles [keV].

Return type:

array_like (N)

eppaurora.spectra.ediss_specfun_int(energy, flux, scale_height, rho, ediss_func, ediss_kws=None, bounds=(0.1, 300.0), nstep=128, spec_fun=<function pflux_maxwell>, spec_kws=None)[source]

Integrate mono-energetic parametrization over a spectrum

Integrates the mono-energetic parametrization over a spectrum given by a functional dependence with characteristic energy energy and total energy flux flux.

Parameters:
  • energy (float or array_like (M,...)) – Characteristic energy E_0 [keV] of the spectral distribution.

  • flux (float or array_like (M,...)) – Integrated energy flux Q_0 [keV / cm² / s¹]

  • scale_height (float or array_like (N,...)) – The atmospheric scale heights [cm].

  • rho (float or array_like (N,...)) – The atmospheric mass density [g / cm³]

  • ediss_func (callable) – Mono-energetic energy dissipation function to integrate.

  • ediss_kws (dict-like, optional) – Optional keyword arguments to pass to the mono-energetic energy dissipation function. Default: None

  • bounds (tuple, optional) – (min, max) [keV] of the integration range to integrate the Maxwellian. Make sure that this is appropriate to encompass the spectrum. Default: (0.1, 300.)

  • nsteps (int, optional) – Number of integration steps, default: 128.

  • spec_func (callable, optional, default pflux_maxwell()) –

    Spectral shape function, choices are:

  • spec_kws (dict-like, optional) – Optional keyword arguments to pass to the spectral function Default: None

Returns:

en_diss – The dissipated energy profiles [keV].

Return type:

array_like (M,N)

See also

ediss_spec_int

eppaurora.spectra.exp_general(en, en_0=10.0)[source]

Exponential number flux spectrum

\[\phi(E, E_0) = 1 / E_0 \cdot \exp\{-E / E_0\}\]

Standard exponential distribution with \(\lambda\) = 1 / en_0 or \(\beta\) = en_0. normalized to unit number flux, i.e. \(\int_0^\infty \phi(E) \text{d}E = 1\).

Parameters:
  • en (float or array_like (N,)) – Energy in [keV]

  • en_0 (float, optional) – Characteristic energy in [keV] of the distribution. Default: 10 keV

Returns:

phi – Normalized differential hemispherical number flux at en in [keV-1 cm-2 s-1] ([keV] or scaled by 1 keV-2 cm-2 s-1, e.g.).

Return type:

float or array_like (N,)

eppaurora.spectra.gaussian_general(en, en_0=10.0, w=1.0)[source]

Gaussian number flux spectrum

Standard normal distribution with \(\mu\) = en_0 and \(\sigma\) = w / sqrt(2):

\[\phi(E, E_0, W) = 1 / \sqrt{\pi}W \cdot \exp\{-(E - E_0)^2 / W^2\}\]

Almost normalized to unit number flux \(\int_0^\infty \phi(E) \text{d}E = 1\) (ignoring the negative tail for large en_0 / w ratios).

Parameters:
  • en (float or array_like (N,)) – Energy in [keV]

  • en_0 (float, optional) – Characteristic energy in [keV], i.e. mode of the distribution. Default: 10 keV

  • w (float, optional) – Width of the Gaussian distribution, in [keV]. Default: 1 keV

Returns:

phi – Normalized differential hemispherical number flux at en in [keV-1 cm-2 s-1] ([keV] or scaled by 1 keV-2 cm-2 s-1, e.g.).

Return type:

float or array_like (N,)

eppaurora.spectra.maxwell_general(en, en_0=10.0)[source]

Maxwell number flux spectrum

\[\phi(E, E_0) = E / E_0^2 \cdot \exp\{-E / E_0\}\]

Equal to a standard Gamma distribution with \(\alpha\) = 2 and \(\beta\) = 1 / en_0, or \(k\) = 2 and \(\theta\) = en_0. Normalized to \(\int_0^\infty \phi(E) \text{d}E = 1\).

Parameters:
  • en (float or array_like (N,)) – Energy in [keV]

  • en_0 (float, optional) – Characteristic energy in [keV], i.e. mode of the distribution. Default: 10 keV

Returns:

phi – Normalized differential hemispherical number flux at en in [keV-1 cm-2 s-1] ([keV] or scaled by 1 keV-2 cm-2 s-1, e.g.).

Return type:

float or array_like (N,)

eppaurora.spectra.pflux_exp(en, en_0=10.0)[source]

Exponential particle flux spectrum

\[\phi(E, E_0) = 1 / E_0^2 \cdot \exp\{-E / E_0\}\]

Normalized to unit energy flux: \(\int_0^\infty \phi(E) E \text{d}E = 1\).

Scales to arbitrary energy flux \(Q\) via multiplication: \(\tilde\phi = Q \cdot \phi\).

Parameters:
  • en (float or array_like (N,)) – Energy in [keV]

  • en_0 (float, optional) – Characteristic energy in [keV], i.e. mode of the distribution. Default: 10 keV.

Returns:

phi – Hemispherical differential particle flux at en in [keV-1 cm-2 s-1] ([keV-2] scaled by unit energy flux).

Return type:

float or array_like (N,)

See also

exp_general

eppaurora.spectra.pflux_gaussian(en, en_0=10.0, w=1)[source]

Gaussian particle flux spectrum

As used in, e.g., Strickland et al., 1993 [23]

\[\phi(E, E_0, W) = 1 / \sqrt{\pi}E_0W \cdot \exp\{-(E - E_0)^2 / W^2\}\]

Normalized to \(\int_0^\infty \phi(E) E \text{d}E = 1\) (ignoring the negative tail).

Scales to arbitrary energy flux \(Q\) via multiplication: \(\tilde\phi = Q \cdot \phi\).

Parameters:
  • en (float or array_like (N,)) – Energy in [keV]

  • en_0 (float, optional) – Characteristic energy in [keV], i.e. mode of the distribution. Default: 10 keV.

Returns:

phi – Hemispherical differential particle flux at en in [keV-1 cm-2 s-1] ([kev-2] scaled by unit energy flux).

Return type:

float or array_like (N,)

References

See also

gaussian_general

eppaurora.spectra.pflux_maxwell(en, en_0=10.0)[source]

Maxwell particle flux spectrum

As used in, e.g., Strickland et al., 1993 [24]

\[\phi(E, E_0) = E / 2E_0^3 \cdot \exp\{-E / E_0\}\]

Equal to a standard Gamma distribution with \(\alpha\) = 3 and \(\beta\) = 1 / en_0, or \(k\) = 3 and \(\theta\) = en_0. The total precipitating energy flux is fixed to 1 keV cm-2 s-1, multiply by Q_0 [keV cm-2 s-1] to scale the particle flux.

Normalized to \(\int_0^\infty \phi(E) E \text{d}E = 1\).

Scales to arbitrary energy flux \(Q\) via multiplication: \(\tilde\phi = Q \cdot \phi\).

Parameters:
  • en (float or array_like (N,)) – Energy in [keV]

  • en_0 (float, optional) – Characteristic energy in [keV], i.e. mode of the distribution. Default: 10 keV.

Returns:

phi – Hemispherical differential particle flux at en in [keV-1 cm-2 s-1] ([kev-2] scaled by unit energy flux).

Return type:

float or array_like (N,)

References

See also

maxwell_general

eppaurora.spectra.pflux_pow(en, en_0=10.0, gamma=-3.0, het=True)[source]

Power-law particle flux spectrum

As used in, e.g., Strickland et al., 1993 [25]

\[\phi(E, E_0, \gamma) = \mp (\gamma + 2) / E_0^2 \cdot (E / E_0)^\gamma\]

The minus-sign (-) and is used for the high-energy tail variant, and the plus-sign (+) for the low-energy tail variant. The exponent gamma needs to be set appropriately, < -1 for het, and > 1 for let.

Normalized to \(\int_{E_0}^\infty \phi(E) E \text{d}E = 1\) for the high-energy tail version, and to \(\int_0^{E_0} \phi(E) E \text{d}E = 1\) for the low-energy tail version.

Scales to arbitrary energy flux \(Q\) via multiplication: \(\tilde\phi = Q \cdot \phi\).

Parameters:
  • en (float or array_like (N,)) – Energy in [keV]

  • en_0 (float, optional) – Characteristic energy in [keV], i.e. mode of the distribution. Default: 10 keV

  • gamma (float, optional) – Exponent of the power-law distribution, in [keV].

  • het (bool, optional (default True)) – Return a high-energy tail (true) for en > en_0, or low-energy tail (false) for en < en_0. Adjusts the normalization accordingly.

Returns:

phi – Hemispherical differential particle flux at en in [keV-1 cm-2 s-1] ([keV-2] scaled by unit energy flux).

Return type:

float or array_like (N,)

References

See also

pow_general

eppaurora.spectra.pow_general(en, en_0=10.0, gamma=-3.0, het=True)[source]

Power-law number flux spectrum

\[\phi(E, E_0, \gamma) = \mp (\gamma + 1) / E_0 \cdot (E / E_0)^\gamma\]

The minus-sign (-) and is used for the high-energy tail variant, and the plus-sign (+) for the low-energy tail variant. The exponent gamma needs to be set appropriately, < -1 for het, and > 1 for let.

The “high-energy tail” version (het = True) resembles a Pareto distribution with scale parameter \(x_m\) = en_0 and shape parameter \(\alpha\) = -(gamma + 1).

Adapted from Strickland et al., 1993 [26] and normalized to unit particle flux: \(\int_{E_0}^\infty \phi(E) \text{d}E = 1\) for the high-energy tail version, and \(\int_0^{E_0} \phi(E) \text{d}E = 1\) for the low-energy tail version.

Parameters:
  • en (float or array_like (N,)) – Energy in [keV]

  • en_0 (float, optional) – Characteristic energy in [keV], i.e. mode of the distribution. Default: 10 keV

  • gamma (float, optional) – Exponent of the power-law distribution, in [keV].

  • het (bool, optional) – Return a high-energy tail (het, default: true) for en > en_0, or low-energy tail (false) for en < en_0. Adjusts the normalization accordingly.

Returns:

phi – Normalized differential hemispherical number flux at en in [keV-1 cm-2 s-1] ([keV] or scaled by 1 keV-2 cm-2 s-1, e.g.).

Return type:

float or array_like (N,)

References

eppaurora.ssusi

Atmospheric ionization rate parametrizations

From the SSUSI ATBD documents [27] [28] [29].

eppaurora.ssusi.ssusi_ioniz(z, en, flux, chmax=[2.07923, -0.0941205], cpmax=[0.0, 0.925777, -0.503201], eref=1.0, pref=2570.0, shpc=14270000000.0)[source]

Parametrization from Sect. 2.6.2 in [30]

Parameters:
  • z (float, array_like) –

  • en (float, array_like) –

  • flux (float, array_like) – Energy flux in [erg cm^{-2} s^{-1}], note: not keV.

  • chmax (tuple, list, (2,) optional) – Pre-determined analytical model coefficients of peak auroral ionization production rate height.

  • cpmax (tuple, list, (3,) optional) – Pre-determined analytical model coefficients of peak auroral ionization production rate

Returns:

q – The atmospheric ionization rate at altitude z.

Return type:

float, array_like

References

Module contents

Atmospheric ionization from auroral particle precipitation

Bundles some of the parametrizations for middle and upper atmospheric ionization and recombination rates for precipitating auroral (100 eV–30 keV) and radiation-belt (30 keV–1 MeV) electrons.