radis.test.lbl.test_broadening module

Created on Tue Jan 9 17:14:01 2018

@author: erwan

Test broadening against HAPI and tabulated data

We’re looking at CO(0->1) line ‘R1’ at 2150.86 cm-1

test_abscoeff_continuum(plot=False, verbose=2, warnings=True, threshold=0.1, *args, **kwargs)[source]

Test calculation with pseudo-continuum

Assert results on abscoeff dont change

Notes

Uses HITRAN so it can deployed and tested on Travis CI, but we should switch to HITEMP if some HITEMP files can be downloaded automatically at the execution time.

test_broadening_DLM(verbose=True, plot=False, *args, **kwargs)[source]

Test use of lineshape template for broadening calculation.

Ensures that results are the same with and without DLM.

test_broadening_DLM_FT(verbose=True, plot=False, *args, **kwargs)[source]

Test use of DLM with and without Fourier Transform

Ensures that results are the same, and compare calculation times.

test_broadening_DLM_noneq(verbose=True, plot=False, *args, **kwargs)[source]

Test Noneq version of DLM and makes sure it gives the same results as the eq one when used with Tvib=Trot

test_broadening_methods_different_conditions(verbose=True, plot=False, *args, **kwargs)[source]

Test direct Voigt broadening vs convolution of Gaussian x Lorentzian for different spectral grid resolution

Notes

Reference broadening calculated manually with the HWHM formula of HITRAN.org

test_broadening_methods_different_wstep(verbose=True, plot=False, *args, **kwargs)[source]

Test direct Voigt broadening vs convolution of Gaussian x Lorentzian for different spectral grid resolution

test_broadening_vs_hapi(rtol=0.01, verbose=True, plot=False, *args, **kwargs)[source]

Test broadening against HAPI and tabulated data

We’re looking at CO(0->1) line ‘R1’ at 2150.86 cm-1

test_broadening_warnings(*args, **kwargs)[source]

Test AccuracyWarning and AccuracyErrors are properly triggered.

Inspired by https://github.com/radis/radis/issues/186

Test _check_accuracy()

Examples

::

AccuracyError: Some lines are too narrow (FWHM ~ 0.0011 cm⁻¹) for the current spectral grid (wstep=0.01). Please reduce wstep to (at least) below 0.00055 cm⁻¹ or (suggested) 0.00022 cm⁻¹

test_noneq_continuum(plot=False, verbose=2, warnings=True, *args, **kwargs)[source]

Test calculation with pseudo-continuum under nonequilibrium

Assert results on emisscoeff dont change

Notes

Uses HITRAN so it can deployed and tested on Travis CI, but we should switch to HITEMP if some HITEMP files can be downloaded automatically at the execution time.