Skip to content

Commit

Permalink
Use sigma_T from astropy constants instead of hardcoding it, also fix…
Browse files Browse the repository at this point in the history
…ing its unit.
  • Loading branch information
ftsamis committed Dec 17, 2016
1 parent 782a0ab commit 136f667
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tardis/montecarlo/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -354,10 +354,10 @@ def from_config(cls, config):
"""
if config.plasma.disable_electron_scattering:
logger.warn('Disabling electron scattering - this is not physical')
sigma_thomson = 1e-200 / (u.cm ** 2)
sigma_thomson = 1e-200 * (u.cm ** 2)
else:
logger.debug("Electron scattering switched on")
sigma_thomson = 6.652486e-25 / (u.cm ** 2)
sigma_thomson = const.sigma_T.cgs

spectrum_frequency = quantity_linspace(
config.spectrum.stop.to('Hz', u.spectral()),
Expand Down

0 comments on commit 136f667

Please sign in to comment.