popsynth.distributions.cosmological_distribution module
- class popsynth.distributions.cosmological_distribution.CosmologicalDistribution(seed: int = 1234, name: str = 'cosmo', form: Optional[str] = None, truth: Dict[str, Any] = {}, is_rate: bool = True)[source]
Bases:
SpatialDistribution
- __init__(seed: int = 1234, name: str = 'cosmo', form: Optional[str] = None, truth: Dict[str, Any] = {}, is_rate: bool = True)[source]
Base class for cosmological spatial distributions.
- Parameters
seed (int) – Random seed
name (str) – Name of the distribution
form (str) – Mathematical description of distribution
truth (dict[str, Any]) – True values of parameters
is_rate (bool) – True if modelling a population of transient events, False if modelling a population of steady-state objects. Affects the
time_adjustment
method used in cosmo calculations. Default is True.
- differential_volume(z)[source]
Differential comoving volume in Gpc^3 sr^-1.
dV/dzdOmega
- Parameters
z – Redshift
- Returns
The differential comoving volume in Gpc^-3 sr^-1.
- class popsynth.distributions.cosmological_distribution.SFRDistribution(seed: int = 1234, name: str = 'sfr', is_rate: bool = True)[source]
Bases:
CosmologicalDistribution
- r0
- a
- rise
- decay
- peak
- __init__(seed: int = 1234, name: str = 'sfr', is_rate: bool = True)[source]
A star-formation like distribution of the form presented in Cole et al. 2001.
r0``(``a``+``rise``z)/(1 + (z/``peak
)^``decay``)- Parameters
seed (int) – Random seed
name (str) – Name of the distribution
is_rate (bool) – True if modelling a population of transient events, False if modelling a population of steady-state objects. Affects the
time_adjustment
method used in cosmo calculations. Default is True.r0 (
DistributionParameter
) – The local density in units of Gpc^-3a (
DistributionParameter
) – Offset at z=0rise (
DistributionParameter
) – Rise at low zdecay (
DistributionParameter
) – Decay at high zpeak (
DistributionParameter
) – Peak of z distribution
- class popsynth.distributions.cosmological_distribution.ZPowerCosmoDistribution(seed: int = 1234, name: str = 'zpow_cosmo', is_rate: bool = True)[source]
Bases:
CosmologicalDistribution
- Lambda
- delta
- __init__(seed: int = 1234, name: str = 'zpow_cosmo', is_rate: bool = True)[source]
A cosmological distribution where the density evolves as a power law.
Lambda
(1+z)^``delta``- Parameters
seed (int) – Random seed
name (str) – Name of the distribution
is_rate (bool) – True if modelling a population of transient events, False if modelling a population of steady-state objects. Affects the
time_adjustment
method used in cosmo calculations. Default is True.Lambda (
DistributionParameter
) – The local density in units of Gpc^-3delta (
DistributionParameter
) – The index of the power law