hmf.density_field.filters.TopHat

class hmf.density_field.filters.TopHat(k, power, **model_parameters)[source]

Real-space top-hat window function.

This class is based on Filter, which can be consulted for details of how to instantiate it.

Notes

This filter specifically implements the real-space filter:

\[F(r) = H(R-r)\]

for a filter size of R, where H is the Heaviside step-function.

Its fourier-transform is

\[W(x=kR) = 3\frac{\sin x - x\cos x}{x^3}.\]

Furthermore the mass-assignment is

\[m(R) = \frac{4\pi}{3} R^3 \bar{\rho}\]

and the derivative of the window function is

\[\frac{dW}{d\ln x}(x=kR) = \frac{1}{x^3}[9x\cos x + 3(x^2-3)\sin x].\]

Methods

__init__(k, power, **model_parameters)

Initialize self.

dlnr_dlnm(r)

The derivative of log radius with log mass.

dlnss_dlnm(r)

The logarithmic slope of mass variance with mass.

dlnss_dlnr(r)

The derivative of the mass variance with radius.

dw_dlnkr(kr)

The derivative of the (fourier-transformed) filter with \(\ln(kr)\).

get_models()

Get a dictionary of all implemented models for this component.

k_space(kr)

Fourier-transform of the real-space filter.

mass_to_radius(m, rho_mean)

Return radius of a region of space given its mass.

nu(r[, delta_c])

Peak height, \(\frac{\delta_c^2}{\sigma^2(r)}\).

radius_to_mass(r, rho_mean)

Return mass of a region of space given its radius

real_space(R, r)

Filter definition in real space.

sigma(r[, order, rk])

Calculate the nth-moment of the smoothed density field, \(\sigma_n(r)\).