optmat.gas.linewidths#

The widths of Raman lines against density, temperature and collision partner.

A Raman line’s full width at half maximum (FWHM) in a gas of number density \(n\) (in amagat) is written

\[\Delta\nu = c + \frac{A(T)}{n} + n \sum_p x_p\, \gamma_p(J, T),\]

with \(c\) a density-independent width, \(A\) the Dicke (motional-narrowing) coefficient of the light molecules, \(x_p\) the mole fraction of the collision partner \(p\) (“self” for the gas itself) and \(\gamma_p\) its broadening coefficient. Three forms of \(\gamma_p\) are used, as the curated data allow:

  • LinewidthLaw: one coefficient for every line of a band, with a temperature law \(\gamma(T) = [\gamma_0 + c_1 (T - T_0) + c_2 (T - T_0)^2] (T_0 / T)^N\) (Broadening), and \(A(T) = A_0 (T / T_A)^{n_A}\);

  • LineTable: a coefficient per rotational level, tabulated at one temperature with a per-level exponent, interpolated in \(J\);

  • ExponentialGapLaw: the modified exponential-gap law of Koszykowski et al. (1987), in which a Q-branch line’s width is the sum of the rates of rotational energy transfer out of its level.

Widths are in Hz, densities in amagat (AMAGAT), temperatures in K. The laws are per line; the overlap of lines at high density (line mixing, the collapse of a Q branch) is not modelled.

Module Attributes

AMAGAT

One amagat, m^-3: the ideal-gas number density at 1 atm and 0 degrees C.

WAVENUMBER_TO_HZ

Factor from a wavenumber in cm^-1 to a frequency in Hz.

Classes

Broadening(coefficient, reference_temperature)

A broadening coefficient and its temperature law.

ExponentialGapLaw(alpha, beta, delta, a, ...)

Q-branch widths from the modified exponential-gap law (Koszykowski et al. 1987).

LineTable(j, coefficient, ...)

Broadening coefficients per rotational level, from one tabulation.

LineTableLaw(tables[, substitutes, dicke, ...])

Per-line widths from per-level tables, one per perturber.

LinewidthLaw([constant, dicke, ...])

One width law for every line of a band.

optmat.gas.linewidths.AMAGAT: float = 2.686780111798444e+25#

One amagat, m^-3: the ideal-gas number density at 1 atm and 0 degrees C.

class optmat.gas.linewidths.Broadening(coefficient, reference_temperature, exponent=0.0, linear=0.0, quadratic=0.0)[source]#

Bases: object

A broadening coefficient and its temperature law.

gamma(T) = [coefficient + linear (T - T0) + quadratic (T - T0)^2] (T0 / T)^exponent in Hz/amagat (FWHM).

Attributes:
coefficientfloat

gamma(T0), Hz/amagat.

reference_temperaturefloat

T0, K.

exponentfloat

The power-law exponent N.

linear, quadraticfloat

Polynomial terms, Hz/amagat/K and Hz/amagat/K^2 (Bischel & Dyer’s law).

at(temperature)[source]#

Return the coefficient at a temperature.

Parameters:
temperaturefloat

Temperature, K, > 0.

Returns:
float

gamma(T), Hz/amagat.

coefficient: float#
exponent: float = 0.0#
linear: float = 0.0#
quadratic: float = 0.0#
reference_temperature: float#
class optmat.gas.linewidths.ExponentialGapLaw(alpha, beta, delta, a, exponent, reference_temperature, b, d=0.0, j_max=60, foreign_as_self=(), sources=())[source]#

Bases: object

Q-branch widths from the modified exponential-gap law (Koszykowski et al. 1987).

The rate of transfer up from level i to j (E_j > E_i, the same nuclear spin symmetry) is gamma_ji = alpha p [(1 + a E_i / (k T delta)) / (1 + a E_i / (k T))]^2 exp(-beta (E_j - E_i) / (k T)), the rate down follows by detailed balance, gamma_ij = (2 J_i + 1) / (2 J_j + 1) gamma_ji exp((E_j - E_i) / (k T)), and the FWHM of line J is 2 sum_{i != J} gamma_iJ (their eqs. 4.1-4.4). alpha scales with temperature as (T0 / T)^n; p is the pressure in atm.

Attributes:
alphafloat

alpha at T0, cm^-1/atm.

beta, delta, afloat

The law’s constants.

exponentfloat

n.

reference_temperaturefloat

T0, K.

b, dfloat

The rotational constants of the levels, cm^-1.

j_maxint

The highest level summed over.

foreign_as_selftuple of str

Collision partners whose broadening is taken as the self-broadening (a declared approximation, where no foreign coefficients are curated).

sourcestuple of str

The formula record and the constants’ datasets.

a: float#
alpha: float#
b: float#
beta: float#
d: float = 0.0#
delta: float#
exponent: float#
foreign_as_self: tuple[str, ...] = ()#
fwhm(j, temperature, density, fractions=None)[source]#

Return the linewidths at a state.

Parameters:
jnumpy.ndarray

The lines’ rotational levels.

temperaturefloat

Temperature, K, > 0.

densityfloat

Total number density, m^-3, > 0 (converted to a pressure with the ideal gas law).

fractionsmapping of str to float, optional

The pure gas, or partners listed in foreign_as_self: the law is for self-broadening.

Returns:
numpy.ndarray

FWHM of each line, Hz.

Raises:
DataError

If a foreign perturber is asked for.

j_max: int = 60#
reference_temperature: float#
sources: tuple[str, ...] = ()#
class optmat.gas.linewidths.LineTable(j, coefficient, reference_temperature, exponent)[source]#

Bases: object

Broadening coefficients per rotational level, from one tabulation.

Between tabulated levels the coefficient and exponent are interpolated linearly in J; beyond the ends they are held at the end values (the linewidths of the highest levels change slowly, and their populations are small).

Attributes:
jtuple of int

The tabulated levels.

coefficienttuple of float

gamma(J, T0), Hz/amagat.

reference_temperaturefloat

T0, K.

exponenttuple of float

The power-law exponent of each level ((T0 / T)^N).

at(j, temperature)[source]#

Return the coefficients of levels j at a temperature.

Parameters:
jnumpy.ndarray

Rotational levels.

temperaturefloat

Temperature, K, > 0.

Returns:
numpy.ndarray

gamma(J, T), Hz/amagat.

coefficient: tuple[float, ...]#
exponent: tuple[float, ...]#
j: tuple[int, ...]#
reference_temperature: float#
class optmat.gas.linewidths.LineTableLaw(tables, substitutes=<factory>, dicke=0.0, sources=())[source]#

Bases: object

Per-line widths from per-level tables, one per perturber.

Attributes:
tablesdict of str to LineTable

By perturber.

substitutesdict of str to str

Perturbers without a table, and the perturber whose table stands in.

dickefloat

A Dicke coefficient A for every line, Hz amagat (H2’s rotational lines).

sourcestuple of str

The curated datasets the tables come from.

dicke: float = 0.0#
fwhm(j, temperature, density, fractions=None)[source]#

Return the linewidths at a state.

Parameters:
jnumpy.ndarray

The lines’ lower rotational levels.

temperaturefloat

Temperature, K, > 0.

densityfloat

Total number density, m^-3, > 0.

fractionsmapping of str to float, optional

Mole fractions by perturber; the pure gas by default.

Returns:
numpy.ndarray

FWHM of each line, Hz.

sources: tuple[str, ...] = ()#
substitutes: Mapping[str, str]#
tables: Mapping[str, LineTable]#
class optmat.gas.linewidths.LinewidthLaw(constant=0.0, dicke=0.0, dicke_temperature=298.0, dicke_exponent=0.0, broadening=<factory>, substitutes=<factory>, sources=())[source]#

Bases: object

One width law for every line of a band.

Attributes:
constantfloat

Density-independent width, Hz.

dickefloat

Dicke coefficient A at dicke_temperature, Hz amagat.

dicke_temperaturefloat

The temperature of dicke, K.

dicke_exponentfloat

n_A in A(T) = A (T / T_A)^n_A.

broadeningdict of str to Broadening

By perturber (self, a gas id, or air).

substitutesdict of str to str

Perturbers without coefficients, and the perturber whose coefficient stands in for each (a declared approximation).

sourcestuple of str

The curated datasets and formulas the law comes from.

broadening: Mapping[str, Broadening]#
constant: float = 0.0#
dicke: float = 0.0#
dicke_exponent: float = 0.0#
dicke_temperature: float = 298.0#
fwhm(j, temperature, density, fractions=None)[source]#

Return the linewidths at a state.

Parameters:
jnumpy.ndarray

The lines’ rotational levels (the width is the same for all).

temperaturefloat

Temperature, K, > 0.

densityfloat

Total number density, m^-3, > 0.

fractionsmapping of str to float, optional

Mole fractions by perturber; the pure gas by default.

Returns:
numpy.ndarray

FWHM of each line, Hz.

sources: tuple[str, ...] = ()#
substitutes: Mapping[str, str]#
optmat.gas.linewidths.WAVENUMBER_TO_HZ: float = 29979245800.0#

Factor from a wavenumber in cm^-1 to a frequency in Hz.