Skip to content

fhtouma/subgen2

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

SubGen2 is a subhalo population generator which works for both CDM and WDM of arbitrary DM particle mass. It can be used to generate a population of subhaloes according to the joint distribution of subhalo bound mass, infall mass and halo-centric distance in a halo of a given mass.

SubGen2 is an extension to the SubGen which works only for CDM subhaloes.

Prerequisites

You need a python installation with the core scientific packages: numpy, matplotlib and scipy. You also need the emcee package(http://dan.iel.fm/emcee) for MCMC sampling. Try

 easy_install numpy matplotlib scipy emcee

or

 pip install numpy matplotlib scipy emcee

to install these dependences if you miss them.

Usage

The usage of this code is almost the same as the SubGen code, except for an additional parameter specifying the WDM particle mass.

For example, to sample subhaloes inside a host halo of mass 1e14 Msun/h, for WDM with a thermal relic particle mass of 1.3 keV

from subgen2 import *
sample=SubhaloSample(M=1e4, WDMmass=1.3) 

Please consult the original SubGen documentation for more instructions and examples at: https://github.com/Kambrian/SubGen

References

If you make use of this code, please cite the following papers:

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages