Skip to content

halomod/hmf

Repository files navigation

hmf

The halo mass function calculator.

Documentation https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/ruff/main/assets/badge/v2.json

hmf is a python application that provides a flexible and simple way to calculate the Halo Mass Function for a range of varying parameters. It is also the backend to TheHaloMod, the online HMF and halo model calculator.

To get started, see the quickstart guide and the API docs.

Important

Pleae remember to cite hmf if you use it in your work. The citation information can be found in the attribution page.

Features

  • Calculate mass functions and related quantities extremely easily.
  • Very simple to start using, but wide-ranging flexibility.
  • Caching system for optimal parameter updates, for efficient iteration over parameter space.
  • Support for all LambdaCDM cosmologies, as well as WDM.
  • Focus on flexibility in models. Each "Component", such as fitting functions, filter functions, growth factor models and transfer function fits are implemented as generic classes that can easily be altered by the user without touching the source code.
  • Focus on simplicity in frameworks. Each "Framework" mixes available "Components" to derive useful quantities -- all given as attributes of the Framework.
  • Comprehensive in terms of output quantities: access differential and cumulative mass functions, mass variance, effective spectral index, growth rate, cosmographic functions and more.
  • Comprehensive in terms of implemented Component models:
    • 5+ models of transfer functions including directly from CAMB
    • 4 filter functions
    • 20 hmf fitting functions
  • Nonlinear power spectra via HALOFIT
  • Functions for sampling the mass function.
  • CLI commands for producing any quantity included.

About

Python halo mass function calculator

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors