hmfast.halos.profiles.NFWMatterProfile

class hmfast.halos.profiles.NFWMatterProfile[source]

Bases: MatterProfile

Matter density profile from Navarro, Frenk & White (1997).

The real-space mass-weighted matter profile is written as

\[u_r(r, M, z) = \frac{1}{\bar{\rho}_{m,0}} \, \frac{\rho_s}{(r/r_s) \left(1+r/r_s\right)^2} \tag{1}\]
\[\rho_s = \frac{M}{4\pi r_s^3} \left[\ln(1+c) - \frac{c}{1+c}\right]^{-1} \tag{2}\]

with \(r_s = r_\Delta / c\).

The Fourier-space mass-weighted matter profile is written as

\[u(k, M, z) = \frac{M}{\bar{\rho}_{m,0}} \left[\ln(1+c) - \frac{c}{1+c}\right]^{-1} \Bigg[ \cos(q) \left(\mathrm{Ci}[(1+c)q] - \mathrm{Ci}(q)\right) + \sin(q) \left(\mathrm{Si}[(1+c)q] - \mathrm{Si}(q)\right) - \frac{\sin(cq)}{(1+c)q} \Bigg] \tag{3}\]

with \(q = k \, r_s \, (1+z)\).

Methods

fourier(halo_model, k, m, z)

Compute the mass-weighted NFW matter profile in Fourier space.

real(halo_model, r, m, z)

Compute the real-space mass-weighted NFW matter profile.

real(halo_model, r, m, z)[source]

Compute the real-space mass-weighted NFW matter profile.

This evaluates Eqs. (1) and (2).

Parameters:
halo_modelHaloModel

Halo model providing the cosmology, concentration relation, and halo radius.

rfloat or jnp.ndarray

Radius or radii in \(\mathrm{Mpc}\).

mfloat or jnp.ndarray

Halo mass(es) in physical \(M_\odot\).

zfloat or jnp.ndarray

Redshift(s).

Returns:
jnp.ndarray

Real-space profile with shape \((N_r, N_m, N_z)\), where singleton dimensions get squeezed before return.

fourier(halo_model, k, m, z)[source]

Compute the mass-weighted NFW matter profile in Fourier space.

This evaluates Eq. (3).

Parameters:
halo_modelHaloModel

Halo model providing the cosmology, concentration relation, and halo radius.

kfloat or jnp.ndarray

Comoving wavenumber(s) in \(\mathrm{Mpc}^{-1}\).

mfloat or jnp.ndarray

Halo mass(es) in physical \(M_\odot\).

zfloat or jnp.ndarray

Redshift(s).

Returns:
jnp.ndarray

Fourier-space profile with shape \((N_k, N_m, N_z)\), where singleton dimensions get squeezed before return.