|
CLUMPY
Version 2011.09_corr2
|
Profile
and related functions (applicable for halos, sub-halos...)
More...

Go to the source code of this file.
Functions | |
| double | rho_ZHAO (double &r, double par[5]) |
| double | rho_EINASTO (double &r, double par[3]) |
| double | rho_EINASTO_N (double &r, double par[3]) |
| string | get_name_prof (double par_prof[4]) |
| double | get_rsat (double par[6]) |
| double | get_rvir (double par[6], double const &rho_vir) |
| void | rho (double &r, double par[6], double &res) |
| void | rho2 (double &r, double par[6], double &res) |
| void | r2rho (double &r, double par[6], double &res) |
| void | r2rho2 (double &r, double par[6], double &res) |
| void | rho_mix (double &r, double par[21], double &res) |
| void | rho2_mix (double &r, double par[21], double &res) |
| void | r2rho_mix (double &r, double par[21], double &res) |
| void | r2rho2_mix (double &r, double par[21], double &res) |
| double | factor_r_2_to_rscale (double par_prof[4]) |
| double | r_2_to_rscale (double const &r_2, double par_prof[4]) |
| double | rscale_to_r_2 (double const &rs, double par_prof[4]) |
| void | set_par0_given_mref (double par[6], double const &r_ref, double const &m_ref, double const &eps) |
| void | set_par0_given_rhoref (double par[6], double &r_ref, double const &rho_ref) |
Profile
and related functions (applicable for halos, sub-halos...)
I. Dark Matter profiles and useful definitions
II. Popular profiles and their parameters
II. Implementation in the code and functions based on 
III. Plots of
,
, and 
A DM profile is fully characterised by a normalisation
, a scale radius
, the physical size of the DM halo (usually taken to be
, the virial radius), and several shape parameters. Note that an important quantity is
, the radius for which the slope is
, i.e.
which can be related to
for any given profile (see below).
We implemented different families of such profiles in CLUMPY, assuming spherical symmetry.
profile (kZHAO in CLUMPY)
family (Hernquist 1990 and Zhao 1996):
- normalisation
. Beware, that with the above definition, 
- scale radius ![$[kpc]$](form_67.png)
- transition slope
- outer slope
- inner slope
.
decreases, which has given rise to several logarithmic inner-slope parameterisations, generally based on the Einasto profile which follows
allows a good description of the density profile of DM halos. Springel et al. (2008) also finds that
describes well the spatial distribution of sub-halos
. For this profile, we have
- normalisation
. With the above definition, we have 
- radius
for which the slope is 
- shape parameter
(kEINASTO_N in CLUMPY)
that differs slightly from the original definition
is adjusted such as the total mass of an Einasto profile is given by Eqs. (20) and (22) of Merritt et al. 2006). For
an integer, which is mandatory in CLUMPY,
. The profile
has been shown to provide good fits to N-body simulations, and
(if
).
- normalisation
. With the above definition, we have 
- radius
which contains half the mass of the halo
- shape parameter (required to be an integer in CLUMPY)
(Graham et al. 2006).
A few useful definitions of functions related to 
- saturation radius
for which
(see params.h). For the ZHAO family,
.
- mass of the DM halo
calculated in mass_singlehalo()
- intrinsic luminosity of the halo calculated in lum_singlehalo(), with
Note that the expressions above are valid for the spherical-halo case only.
II. Popular profiles and their parameters
Dark matter simulations usually provide
(from the total density of DM measured in shells) and
, the spatial distribution of sub-clumps within a clump. The above families of profiles can be used to describe both the total DM density of a clump and their spatial distribution. Remember however that they will come with different values of their structural parameters
,
, etc.
In CLUMPY, we generically call
the scale radius appearing in the different profiles. However, depending on the chosen parameterisation, it can mean
,
or
(see profiles.h). It is up to the user to check that the values for
he/she uses in the input parameter file are "realistic". In the same spirit, there are three shape parameters denoted
,
, and
, although only
is used for kEINASTO and kEINASTO_N (for which
corresponds to
). The table below provides several shape parameters proposed in the literature. They also gives some "reasonable" values as found from simulations for the scale parameter for the Galaxy (or Galactic-type halos). Use with caution!
| | | Refs | | | |
|---|---|---|---|---|---|---|
| Iso | 2. | 2. | 0. | - | 4 kpc | 28 kpc |
| NFW | 1. | 3. | 1. | Navarro, Frenk & White (1997) | 21.7 kpc | - |
| Moore | 1.5 | 3. | 1.5 | Moore et al. (1998) | 34.5 kpc | - |
| DMS04 | 1. | 3. | 1.2 | Diemand, Moore & Stadel (2004) | 32.6 | - |
| EINASTO_N | 6 | - | - | Merritt et al. (2006) | 250 kpc | - |
| EINASTO | 0.17 | - | - | Navarro et al. (2004), Springel et al. (2008) | 21.7 kpc | - |
| EINASTO | 0.68 | - | - | Springel et al. (2008) | - | 199 kpc |
From Lavalle et al. (2008).
From Tab. II of Fornengo, Pieri & Scopel (2004).
III. Implementation in the code and functions based on 
For all applications and functions in other parts of the code (e.g., in clumps.h, jdsph.h), the profile families are never called directly. In practice, we use functions that can switch to the desired quantity: this switch is set by picking a value of the global enum gENUM_PROFILE constants, which is associated to the string name gNAMES_PROFILE[gENUM_PROFILE] (see params.h).
Beware that this "scale" radius means different things depending on what profile is considered:
for standard configurations,
for EINASTO, and
for EINASTO_N. A list of "reasonable" values of
taken from the above papers can be found above. In any case, the function set_par0_given_rhoref() will ensure that the proper normalisation par[0] is calculated, according to the specified "scale" radius.
For instance, setting the switch to the value kZHAO, gives gNAMES_PROFILE[kZHAO] = "ZHAO". This applies all the above profiles. Let us now describe all the functions of this file:
| [in] | r | Distance from the halo centre [kpc] |
| [in] | par[0] | Normalisation: density or proxy for |
| [in] | par[1] | Scale radius [kpc] |
| [in] | par[2] | Shape parameter #1 |
| [in] | par[3] | Shape parameter #2 |
| [in] | par[4] | Shape parameter #3 |
, where XXX = ZHAO, EINASTO, or EINASTO_N fn(double &r, double par[6], double &res), to get functions of
. | [in] | r | Radial distance from the halo centre [kpc] |
| [in] | par[0] | Normalisation: density or proxy for |
| [in] | par[1] | Scale radius [kpc] |
| [in] | par[2] | Shape parameter #1 |
| [in] | par[3] | Shape parameter #2 |
| [in] | par[4] | Shape parameter #3 |
| [in] | par[5] | card_profile (see enum gENUM_PROFILE in params.h) |
| [out] | res | , , , or . |
fn(double &r, double par[21], double &res), such that they can be passed to the integrator for a more general profile (e.g.,
| [in] | r | Radial distance from the halo centre [kpc] |
| [in] | par[0] | normalisation: density or proxy for |
| [in] | par[1] | scale radius [kpc] |
| [in] | par[2] | shape parameter #1 |
| [in] | par[3] | shape parameter #2 |
| [in] | par[4] | shape parameter #3 |
| [in] | par[5] | card_profile (see enum gENUM_PROFILE in params.h) |
| [in] | par[6] | UNUSED |
| [in] | par[7] | UNUSED |
| [in] | par[8] | UNUSED |
| [in] | par[9] | UNUSED |
| [in] | par[10] | switch_rho - selects which combination of and to use
|
| [in] | par[11] | normalisation: density or proxy for |
| [in] | par[12] | scale radius [kpc] |
| [in] | par[13] | shape parameter #1 |
| [in] | par[14] | shape parameter #2 |
| [in] | par[15] | shape parameter #3 |
| [in] | par[16] | card_profile (see enum gENUM_PROFILE in params.h) |
| [in] | par[17] | UNUSED |
| [in] | par[18] | UNUSED |
| [in] | par[19] | UNUSED |
| [in] | par[20] | UNUSED |
| [out] | res | , , , or . |
string of the profile name/parameters to be used in displays | [in] | par_prof[0] | Shape parameter #1 |
| [in] | par_prof[1] | Shape parameter #2 |
| [in] | par_prof[2] | Shape parameter #3 |
| [in] | par_prof[3] | card_profile (see enum gENUM_PROFILE in params.h) |
| [in] | par[0] | Normalisation: density or proxy for |
| [in] | par[1] | Scale radius [kpc] |
| [in] | par[2] | Shape parameter #1 |
| [in] | par[3] | Shape parameter #2 |
| [in] | par[4] | Shape parameter #3 |
| [in] | par[5] | card_profile (see enum gENUM_PROFILE in params.h) |
[kpc] for which
. | [in] | par[0] | Normalisation: density or proxy for |
| [in] | par[1] | Scale radius [kpc] |
| [in] | par[2] | Shape parameter #1 |
| [in] | par[3] | Shape parameter #2 |
| [in] | par[4] | Shape parameter #3 |
| [in] | par[5] | card_profile (see enum gENUM_PROFILE in params.h) |
| [in] | rho_vir | DM density we wish to reach at the viral radius |
[kpc] such as to have
. | [in] | par[0] | Shape parameter #1 |
| [in] | par[1] | Shape parameter #2 |
| [in] | par[2] | Shape parameter #3 |
| [in] | par[3] | card_profile (see enum gENUM_PROFILE in params.h) |
, the factor to convert
to
and vice-versa. | [in] | r_2(rs) | Radius from which the slope is -2 (or scale radius ) [kpc] |
| [in] | par[0] | Shape parameter #1 |
| [in] | par[1] | Shape parameter #2 |
| [in] | par[2] | Shape parameter #3 |
| [in] | par[3] | card_profile (see enum gENUM_PROFILE in params.h) |
(or radius
from which the slope is -2) [kpc] | [out] | par[0] | Proper normalisation to ensure for this profile |
| [in] | par[1] | Scale radius [kpc] |
| [in] | par[2] | Shape parameter #1 |
| [in] | par[3] | Shape parameter #2 |
| [in] | par[4] | Shape parameter #3 |
| [in] | par[5] | card_profile (see enum gENUM_PROFILE in params.h) |
| [in] | r_ref | Reference radius [kpc] |
| [in] | m_ref | Mass within r_ref [ ] |
| [in] | eps | - relative precision sought for the integration |
| [out] | par[0] | Proper normalisation to ensure for this profile |
| [in] | par[1] | Scale radius [kpc] |
| [in] | par[2] | Shape parameter #1 |
| [in] | par[3] | Shape parameter #2 |
| [in] | par[4] | Shape parameter #3 |
| [in] | par[5] | card_profile (see enum gENUM_PROFILE in params.h) |
| [in] | r_ref | Reference radius [kpc] |
| [in] | rho_ref | DM density value for the reference radius r_ref ![]() |
The following figures display a comparison of the various profiles in central regions. The saturation density is reached for some of them (1
)
(normalised to
at
)
mass
intrinsic luminosity
)
and luminosity
of a clump, the function shown in the last two previous plots need to be integrated. We split the integration in several parts to speed-up the calculation:
is integrated with the linear step simpson_lin_adapt(), and the second and third parts
and
are integrated with the adaptive logarithmic step simpson_log_adapt(), as described in integr.h. Definition in file profiles.h.