Absorption Module Methods & Types
Downloading HITRAN Data
vSmartMOM.artifact
— Functionartifact(molecule::AbstractString, database::AbstractString = "hitran")
Given a molecule name and a database name, retrieve the transition file
Reading HITRAN Files
vSmartMOM.Absorption.read_hitran
— Functionread_hitran(filepath::String, mol::Int=-1, iso::Int=-1, ν_min::Real=0, ν_max::Real=Inf)
Read/parse a HITRAN data file and return the data in HitranTable
format
Defining Models with Cross-Section Parameters
vSmartMOM.Absorption.make_hitran_model
— Functionmake_hitran_model(hitran::HitranTable,
broadening::AbstractBroadeningFunction;
wing_cutoff::Real=40,
vmr::Real=0,
CEF::AbstractComplexErrorFunction=HumlicekWeidemann32SDErrorFunction(),
architecture = default_architecture)
Convenience function to make a HitranModel out of the parameters (Matches makeinterpolationmodel)
vSmartMOM.Absorption.make_interpolation_model
— Functionmake_interpolation_model(hitran::HitranTable,
broadening::AbstractBroadeningFunction,
wave_grid::AbstractRange{<:Real},
p_grid::AbstractRange{<:Real},
t_grid::AbstractRange{<:Real};
wavelength_flag::Bool=false,
wing_cutoff::Real=40,
vmr::Real=0,
CEF::AbstractComplexErrorFunction=HumlicekWeidemann32SDErrorFunction(),
architecture::AbstractArchitecture=default_architecture )
Using a HitranModel, create an InterpolationModel by interpolating the lineshape function at the given pressure and temperature grids
Computing Absorption Cross-Sections
vSmartMOM.Absorption.absorption_cross_section
— Functionabsorption_cross_section(model::HitranModel, grid::AbstractRange{<:Real}, pressure::Real, temperature::Real; wavelength_flag::Bool=false)
Calculate absorption cross-section at the given pressure, temperature, and grid of wavelengths (or wavenumbers), and have the option to perform auto-differentiation
Types
Hitran Data Structure Type
vSmartMOM.Absorption.HitranTable
— Typestruct HitranTable{FT}
A struct, which provides all HITRAN line parameters needed to compute absorption cross sections
See https://hitran.org/docs/definitions-and-units/ for details
Fields
mol
The molecular species identification (ID) number
iso
The isotopologue ID number
νᵢ
The wavenumber of the spectral line transition (cm-1) in vacuum
Sᵢ
The spectral line intensity (cm−1/(molecule·cm−2)) at Tref=296K
Aᵢ
The Einstein-A coefficient (s-1) of a transition
γ_air
The air-broadened half width at half maximum (HWHM) (cm−1/atm) at Tref=296K and reference pressure pref=1atm
γ_self
The self-broadened half width at half maximum (HWHM) (cm−1/atm) at Tref=296K and reference pressure pref=1atm
E″
The lower-state energy of the transition (cm-1)
n_air
The coefficient of the temperature dependence of the air-broadened half width
δ_air
The pressure shift (cm−1/atm) at Tref=296K and pref=1atm of the line position with respect to the vacuum transition wavenumber νij
global_upper_quanta
The electronic and vibrational quantum numbers and labels for the upper state of a transition
global_lower_quanta
The electronic and vibrational quantum numbers and labels for the lower state of a transition
local_upper_quanta
Rotational, hyperfine and other quantum numbers and labels for the upper state of a transition
local_lower_quanta
Rotational, hyperfine and other quantum numbers and labels for the lower state of a transition
ierr
Ordered list of indices corresponding to uncertainty estimates of transition parameters
iref
Ordered list of reference identifiers for transition parameters
line_mixing_flag
A flag indicating the presence of additional data and code relating to line-mixing
g′
The upper state degeneracy
g″
The lower state degeneracy
Broadening Function Types
vSmartMOM.Absorption.Doppler
— TypeDoppler line broadening
vSmartMOM.Absorption.Lorentz
— TypeLorentz line broadening
vSmartMOM.Absorption.Voigt
— TypeVoigt line broadening
Complex Error Function Types
vSmartMOM.Absorption.HumlicekErrorFunction
— TypeHumlicek only formulation for Complex Error Function
vSmartMOM.Absorption.HumlicekWeidemann32VoigtErrorFunction
— TypeMix of Humlicek and Weidemann (N=32) Error Function, suggested for Voigt function
vSmartMOM.Absorption.HumlicekWeidemann32SDErrorFunction
— TypeMix of Humlicek and Weidemann (N=32) Error Function, suggested for Speed Dependent Voigt function
vSmartMOM.Absorption.CPF12ErrorFunction
— TypeHumlicek with a single rational approximation.
vSmartMOM.Absorption.ErfcHumliErrorFunctionVoigt
— TypeMix of Humplicek and erfc Special Function for Voigt
vSmartMOM.Absorption.ErfcHumliErrorFunctionSD
— TypeMix of Humplicek and erfc Special Function for Voigt
vSmartMOM.Absorption.ErfcErrorFunction
— Typeerfc Special Function for Voigt
Cross-Section Model Types
vSmartMOM.Absorption.HitranModel
— Typestruct HitranModel{FT}
A struct which provides all model parameters needed for cross-section calculations using HITRAN data
Fields
hitran
Struct with hitran data
broadening
Broadening function (Doppler/Lorentz/Voigt)
wing_cutoff
Wing cutoff [cm-1]
vmr
VMR of gas itself [0-1]
CEF
Complex Error Function to Use
architecture
Computer
Architecture
on whichModel
is run
vSmartMOM.Absorption.InterpolationModel
— Typestruct InterpolationModel{FT}
A struct which provides all model parameters needed for cross-section calculations using an Interpolator
Fields
itp
The interpolator
mol
The molecular species identification (ID) number
iso
The isotopologue ID number
ν_grid
Wavelength grids
p_grid
Wavelength grids
t_grid
Wavelength grids