CCL
Typedefs | Enumerations | Functions
ccl_background.h File Reference
#include "ccl_core.h"

Go to the source code of this file.

Typedefs

typedef enum ccl_omega_x_label ccl_omega_x_label
 

Enumerations

enum  ccl_omega_x_label {
  ccl_omega_m_label =0, ccl_omega_l_label =1, ccl_omega_g_label =2, ccl_omega_k_label =3,
  ccl_omega_ur_label =4, ccl_omega_nu_label =5
}
 

Functions

double ccl_h_over_h0 (ccl_cosmology *cosmo, double a, int *status)
 
void ccl_h_over_h0s (ccl_cosmology *cosmo, int na, double a[na], double output[na], int *status)
 
double ccl_comoving_radial_distance (ccl_cosmology *cosmo, double a, int *status)
 
void ccl_comoving_radial_distances (ccl_cosmology *cosmo, int na, double a[na], double output[na], int *status)
 
double ccl_sinn (ccl_cosmology *cosmo, double chi, int *status)
 
double ccl_comoving_angular_distance (ccl_cosmology *cosmo, double a, int *status)
 
void ccl_comoving_angular_distances (ccl_cosmology *cosmo, int na, double a[na], double output[na], int *status)
 
double ccl_luminosity_distance (ccl_cosmology *cosmo, double a, int *status)
 
void ccl_luminosity_distances (ccl_cosmology *cosmo, int na, double a[na], double output[na], int *status)
 
double ccl_distance_modulus (ccl_cosmology *cosmo, double a, int *status)
 
void ccl_distance_moduli (ccl_cosmology *cosmo, int na, double a[na], double output[na], int *status)
 
double ccl_growth_factor (ccl_cosmology *cosmo, double a, int *status)
 
void ccl_growth_factors (ccl_cosmology *cosmo, int na, double a[na], double output[na], int *status)
 
double ccl_growth_factor_unnorm (ccl_cosmology *cosmo, double a, int *status)
 
void ccl_growth_factors_unnorm (ccl_cosmology *cosmo, int na, double a[na], double output[na], int *status)
 
double ccl_growth_rate (ccl_cosmology *cosmo, double a, int *status)
 
void ccl_growth_rates (ccl_cosmology *cosmo, int na, double a[na], double output[na], int *status)
 
double ccl_scale_factor_of_chi (ccl_cosmology *cosmo, double chi, int *status)
 
void ccl_scale_factor_of_chis (ccl_cosmology *cosmo, int nchi, double chi[nchi], double output[nchi], int *status)
 
double ccl_omega_x (ccl_cosmology *cosmo, double a, ccl_omega_x_label label, int *status)
 

Typedef Documentation

◆ ccl_omega_x_label

Enumeration Type Documentation

◆ ccl_omega_x_label

Enumerator
ccl_omega_m_label 
ccl_omega_l_label 
ccl_omega_g_label 
ccl_omega_k_label 
ccl_omega_ur_label 
ccl_omega_nu_label 

Function Documentation

◆ ccl_comoving_angular_distance()

double ccl_comoving_angular_distance ( ccl_cosmology cosmo,
double  a,
int *  status 
)

Comoving angular distance in Mpc from today to scale factor a NOTE this quantity is otherwise known as the transverse comoving distance, and is NOT angular diameter distance or angular separation

Parameters
cosmoCosmological parameters
ascale factor, normalized to 1 for today
statusStatus flag. 0 if there are no errors, nonzero otherwise. For specific cases see documentation for ccl_error.c
Returns
comoving_angular_distance, the angular distance in Mpc

◆ ccl_comoving_angular_distances()

void ccl_comoving_angular_distances ( ccl_cosmology cosmo,
int  na,
double  a[na],
double  output[na],
int *  status 
)

Comoving angular distances in Mpc to scale factors as given in array a[0..na-1] NOTE this quantity is otherwise known as the transverse comoving distance, and is NOT angular diameter distance or angular separation

Parameters
cosmoCosmological parameters
naNumber of scale factors in a
aarray of scale factors
outputarray of length na to store the results of the calculation. The entry at index i stores the distance for a[i].
statusStatus flag. 0 if there are no errors, nonzero otherwise. For specific cases see documentation for ccl_error.
Returns
void

◆ ccl_comoving_radial_distance()

double ccl_comoving_radial_distance ( ccl_cosmology cosmo,
double  a,
int *  status 
)

Comoving radial distance in Mpc from today to scale factor a

Parameters
cosmoCosmological parameters
ascale factor, normalized to 1 for today
statusStatus flag. 0 if there are no errors, nonzero otherwise. For specific cases see documentation for ccl_error.c
Returns
comoving_radial_distance, Comoving radial distance in Mpc

◆ ccl_comoving_radial_distances()

void ccl_comoving_radial_distances ( ccl_cosmology cosmo,
int  na,
double  a[na],
double  output[na],
int *  status 
)

Comoving radial distances in Mpc to scale factors as given in list a[0..na-1]

Parameters
cosmoCosmological parameters
naNumber of scale factors in a
aarray of scale factors
outputarray of length na to store the results of the calculation. The entry at index i stores the distance for a[i].
statusStatus flag. 0 if there are no errors, nonzero otherwise. For specific cases see documentation for ccl_error.
Returns
void

◆ ccl_distance_moduli()

void ccl_distance_moduli ( ccl_cosmology cosmo,
int  na,
double  a[na],
double  output[na],
int *  status 
)

Distance moduli for objects at scale factors as given in list a[0..na-1]. Note the factor of 6 arises from the conversion from Mpc to pc.

Parameters
cosmoCosmological parameters
naNumber of scale factors in a
aarray of scale factors
outputarray of length na to store the results of the calculation. The entry at index i stores the distance for a[i].
statusStatus flag. 0 if there are no errors, nonzero otherwise. For specific cases see documentation for ccl_error.
Returns
void

◆ ccl_distance_modulus()

double ccl_distance_modulus ( ccl_cosmology cosmo,
double  a,
int *  status 
)

Distance modulus for object at scale factor a. Note the factor of 6 arises from the conversion from Mpc to pc.

Parameters
cosmoCosmological parameters
ascale factor, normalized to 1 today
statusStatus flag. 0 if there are no errors, nonzero otherwise. For specific cases see documentation for ccl_error.
Returns
distance modulus

◆ ccl_growth_factor()

double ccl_growth_factor ( ccl_cosmology cosmo,
double  a,
int *  status 
)

Growth factor at scale factor a, where g(z=0) is normalized to 1

Parameters
cosmoCosmological parameters
ascale factor, normalized to 1 for today
statusStatus flag. 0 if there are no errors, nonzero otherwise. For specific cases see documentation for ccl_error.c
Returns
growth_factor, growth factor at a

◆ ccl_growth_factor_unnorm()

double ccl_growth_factor_unnorm ( ccl_cosmology cosmo,
double  a,
int *  status 
)

Growth factor at scale factor a, where g(a) is normalized to a in matter domination

Parameters
cosmoCosmological parameters
ascale factor, normalized to 1 for today
statusStatus flag. 0 if there are no errors, nonzero otherwise. For specific cases see documentation for ccl_error.c
Returns
growth_factor_unnorm, Unnormalized growth factor, normalized to the scale factor at early times.

◆ ccl_growth_factors()

void ccl_growth_factors ( ccl_cosmology cosmo,
int  na,
double  a[na],
double  output[na],
int *  status 
)

Growth factors at an array of scale factor given in a[0..na-1], where g(z=0) is normalized to 1

Parameters
cosmoCosmological parameters
naNumber of scale factors in a
aarray of scale factors
outputarray of length na to store the results of the calculation. The entry at index i stores the distance for a[i].
statusStatus flag. 0 if there are no errors, nonzero otherwise. For specific cases see documentation for ccl_error.
Returns
void

◆ ccl_growth_factors_unnorm()

void ccl_growth_factors_unnorm ( ccl_cosmology cosmo,
int  na,
double  a[na],
double  output[na],
int *  status 
)

Growth factors at a list of scale factor given in a[0..na-1], where g(a) is normalized to a in matter domination

Parameters
cosmoCosmological parameters
naNumber of scale factors in a
aarray of scale factors
outputarray of length na to store the results of the calculation. The entry at index i stores the distance for a[i].
statusStatus flag. 0 if there are no errors, nonzero otherwise. For specific cases see documentation for ccl_error.
Returns
void

◆ ccl_growth_rate()

double ccl_growth_rate ( ccl_cosmology cosmo,
double  a,
int *  status 
)

Logarithmic rate of d ln(g)/d ln(a) at scale factor a

Parameters
cosmoCosmological parameters
ascale factor, normalized to 1 for today
statusStatus flag. 0 if there are no errors, nonzero otherwise. For specific cases see documentation for ccl_error.c
Returns
f, the growth rate at a

◆ ccl_growth_rates()

void ccl_growth_rates ( ccl_cosmology cosmo,
int  na,
double  a[na],
double  output[na],
int *  status 
)

Logarithmic rates of d ln(g)/d ln(a) at an array of scale factors a[0..na-1]

Parameters
cosmoCosmological parameters
naNumber of scale factors in a
aarray of scale factors
outputarray of length na to store the results of the calculation. The entry at index i stores the distance for a[i].
statusStatus flag. 0 if there are no errors, nonzero otherwise. For specific cases see documentation for ccl_error.
Returns
void

◆ ccl_h_over_h0()

double ccl_h_over_h0 ( ccl_cosmology cosmo,
double  a,
int *  status 
)

Normalized expansion rate at scale factor a. Returns H(a)/H0 in a given cosmology.

Parameters
cosmoCosmological parameters
ascale factor, normalized to 1 for today
statusStatus flag. 0 if there are no errors, nonzero otherwise. For specific cases see documentation for ccl_error.c
Returns
h_over_h0, the value of H(a)/H0.

◆ ccl_h_over_h0s()

void ccl_h_over_h0s ( ccl_cosmology cosmo,
int  na,
double  a[na],
double  output[na],
int *  status 
)

Normalized expansion rate at scale factors as given in list a[0..na-1] Returns H(a)/H0 for an array of scale factors a of length na.

Parameters
cosmoCosmological parameters
naNumber of scale factors in a
aarray of scale factors
outputarray of length na to store the results of the calculation. The entry at index i stores H(a[i])/H0
statusStatus flag. 0 if there are no errors, nonzero otherwise. For specific cases see documentation for ccl_error.
Returns
void

◆ ccl_luminosity_distance()

double ccl_luminosity_distance ( ccl_cosmology cosmo,
double  a,
int *  status 
)

Comoving luminosity distance in Mpc from today to scale factor a

Parameters
cosmoCosmological parameters
ascale factor, normalized to 1 for today
statusStatus flag. 0 if there are no errors, nonzero otherwise. For specific cases see documentation for ccl_error.c
Returns
luminosity_distance, the angular distance in Mpc

◆ ccl_luminosity_distances()

void ccl_luminosity_distances ( ccl_cosmology cosmo,
int  na,
double  a[na],
double  output[na],
int *  status 
)

Comoving luminosity distances in Mpc to scale factors as given in array a[0..na-1]

Parameters
cosmoCosmological parameters
naNumber of scale factors in a
aarray of scale factors
outputarray of length na to store the results of the calculation. The entry at index i stores the distance for a[i].
statusStatus flag. 0 if there are no errors, nonzero otherwise. For specific cases see documentation for ccl_error.
Returns
void

◆ ccl_omega_x()

double ccl_omega_x ( ccl_cosmology cosmo,
double  a,
ccl_omega_x_label  label,
int *  status 
)

Density fraction of a given species at a redshift different than z=0.

Parameters
cosmoCosmological parameters
ascale factor, normalized to 1 for today
labelspecies type. Available: 'matter' (0), 'dark_energy'(1), 'radiation'(2), and 'curvature'(3)
statusStatus flag. 0 if there are no errors, nonzero otherwise. For specific cases see documentation for ccl_error.
Returns
omega_x, Density fraction of a given species at scale factor a.

◆ ccl_scale_factor_of_chi()

double ccl_scale_factor_of_chi ( ccl_cosmology cosmo,
double  chi,
int *  status 
)

Scale factor for a given comoving distance (in Mpc)

Parameters
cosmoCosmological parameters
chiComoving distance in Mpc
statusStatus flag. 0 if there are no errors, nonzero otherwise. For specific cases see documentation for ccl_error.
Returns
a, scale factor of distance xi

◆ ccl_scale_factor_of_chis()

void ccl_scale_factor_of_chis ( ccl_cosmology cosmo,
int  nchi,
double  chi[nchi],
double  output[nchi],
int *  status 
)

Scale factors for a given array of comoving distances chi[0..nchi-1]

Parameters
cosmoCosmological parameters
nchiNumber of chis in chi
chiarray of comoving distances
outputarray of length na to store the results of the calculation. The entry at index i stores the scale factor for chi[i].
statusStatus flag. 0 if there are no errors, nonzero otherwise. For specific cases see documentation for ccl_error.
Returns
void

◆ ccl_sinn()

double ccl_sinn ( ccl_cosmology cosmo,
double  chi,
int *  status 
)

Transforms between radial and transverse comoving distances Calculate the comoving radial distance of two objects with comoving radial distance chi via: { sin(x) , if k==1 sinn(x)={ x , if k==0 { sinh(x) , if k==-1

Parameters
cosmoCosmological parameters
chiComoving radial distance of two objects
statusStatus flag. 0 if there are no errors, nonzero otherwise. For specific cases see documentation for ccl_error.
Returns
chi_t, the transverse comoving distance