gphist.cosmology module

Homegenous cosmology.

gphist.cosmology.get_DH(z, model=None)

Evaluates the distance function DH(z).

Parameters:
  • z (ndarray) – Array of redshifts where DH(z) = c/H(z) should be evaluated.
  • model – subclass of astropy.cosmology.FLRW that defines the homogeneous cosmology model to use. If None, uses get_fiducial().
Returns:

Array of values of DH(z) = c/H(z) in Mpc.

Return type:

ndarray

gphist.cosmology.get_acceleration(z, DH)

Calculates the cosmic acceleration H(z)/(1+z).

Parameters:
  • z (ndarray) – Array of redshifts where DH is tabulated.
  • DH (ndarray) – Array of Hubble distances DH(z) = c/H(z). Must have the same last dimension as z.
Returns:

Array of calculated H(z)/(1+z) values with the same

shape as the input DH array.

Return type:

ndarray

gphist.cosmology.get_dark_energy_evolution(z, DH)

Calculates the dark energy density evolution.

Parameters:
  • z (ndarray) – Array of redshifts where DH is tabulated.
  • DH (ndarray) – Array of Hubble distances DH(z) = c/H(z). Must have the same last dimension as z.
Returns:

Array with shape (2,...) where (...) is the shape of DH. The

[0] element gives values of omega_phi(z)/h0**2 for each entry in DH. The [1] element gives values of omega_phi(z)/h(z)**2 for each entry in DH.

Return type:

ndarray

gphist.cosmology.get_fiducial()

Returns the fiducial homogenous cosmology model.

The fiducial model is derived from the Planck+WP best fit to flat LCDM in Ade 2013, given in the 6th column of Table 2 in the paper.

gphist.cosmology.get_model()
gphist.cosmology.get_omega_matter_evolution(z, DH)

Calculates the dark energy density evolution.

Args: z(ndarray): Array of redshifts where DH is tabulated. DH(ndarray): Array of Hubble distances DH(z) = c/H(z). Must have the same last dimension as z.

Returns: ndarray: Array with shape (2,...) where (...) is the shape of DH. The [0] element gives values of omega_phi(z)/h0**2 for each entry in DH. The [1] element gives values of omega_phi(z)/h(z)**2 for each entry in DH.

gphist.cosmology.get_omega_radiation(z, model=None)

Evaluates the physical radiation density.

Evaluates the combined photon and neutrino (massless + massive) physical density using the WMAP7 treatment of massive neturinos (Komatsu et al. 2011, ApJS, 192, 18, section 3.3).

Parameters:
  • z (ndarray) – Array of redshifts where DH(z) = c/H(z) should be evaluated.
  • model – subclass of astropy.cosmology.FLRW that defines the homogeneous cosmology model to use. If None, uses get_fiducial().
Returns:

Array of values of omega_r(z) = (Omega_gamma(z) + Omega_nu(z))*h0**2.

Return type:

ndarray