Struct RhoECoupling

Source
pub struct RhoECoupling {
    pub rho_e_old: f64,
    pub r_compton: f64,
    pub rho_source: f64,
    pub lambda_exp: f64,
    pub dh_drho: f64,
    pub h_norm: f64,
}
Expand description

Parameters for coupling ρ_e into the bordered Newton system.

When passed to kompaneets_step_coupled_inplace, ρ_e becomes the (N+1)-th unknown solved simultaneously with Δn. The system becomes bordered tridiagonal, solved in O(N) via two Thomas solves.

Fields§

§rho_e_old: f64

ρ_e at the start of this timestep (before update_temperatures).

§r_compton: f64

Compton coupling coefficient R = (8/3)(ρ̃_γ/α_h). This is the rate at which Compton scattering drives ρ_e → ρ_eq, per unit Thomson optical depth.

§rho_source: f64

Source term in the ρ_e ODE: R·ρ_eq + δρ_inj.

§lambda_exp: f64

Adiabatic cooling rate: H·t_C.

§dh_drho: f64

dH_dcbr/dρ_e (finite-difference derivative from update_temperatures).

§h_norm: f64

Normalization for H_dcbr integral: 1/(4·G₃·θ_z).

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.