Recombination

Recombination#

class discoeb.components.recombination.Recombination(**overrides)[source]#

Bases: Component

The thermal history every solve integrates once per cosmology: the interface a recombination code fills.

It holds the conformal time tau and the optical depth kappa as driver states and provides what the perturbations and DISCO-CMB read: tau, the opacity kappa' = x_e n_H sigma_T a and the baryon sound speed cs2. A subclass is one recombination code, such as RECFAST, and provides three quantities from states of its own:

  • xe_rec, the free electrons per hydrogen nucleus from recombination alone,

  • Tmat, the matter temperature in K,

  • dTm_dz, its rate in redshift, which cs2 reads.

The class adds CAMB’s tanh reionization (z_re) to xe_rec. The solve integrates in the scale factor, so a is the time itself and tau a state whose rate is one (per unit of itself: the solve divides every rate by a', Equations). It starts from the radiation era’s closed form, and its value today is the conformal age. kappa integrates the opacity from a = 6e-4 on, and DISCO-CMB forms the visibility kappa'(tau) exp(-(kappa(tau_0) - kappa(tau))) from it. Nothing marks these states as the background: their rates read no wave number, and Equations.stages finds that.

class discoeb.components.recfast.RECFAST(**overrides)[source]#

Bases: Recombination

RECFAST’s (x_H, x_He, T_m) as the state thermo, whose rates in z convert with dz/dtau = -aH / a.

It provides the three quantities Recombination asks of a recombination code: xe_rec = x_H + fHe x_He, Tmat and its rate dTm_dz, with no spline derivative.

class discoeb.components.recombination.ReionizationDepth(**overrides)[source]#

Bases: Component

The optical depth of reionization as a state: kappa_reio, whose value today is tau_reio.

A model adds it to read tau_reio off a solve or to differentiate in the reionization redshift, LCDM.add(ReionizationDepth, name=...). kappa_reio integrates the opacity of the electrons reionization frees, a background state beside Recombination’s. A launch weights it (REIO_ERROR_WEIGHT) so that the steps resolve the reionization step’s derivative in z_re. Without the state the derivative is inaccurate.