7 #define GROWTH_TOLERANCE 1.0e-4 35 FILE * f = fopen(filename,
"r");
39 fscanf(f,
"%*[^\n]\n", NULL);
43 for(
int i_z=0; i_z<
N_Z; i_z++) {
44 for(
int i_model=0; i_model<N_MODEL+1; i_model++) {
45 int count = fscanf(f,
"%le", &val);
53 gf[i_z][i_model-1] = val;
76 double Omega_v[
N_MODEL] = { 0.7, 0.7, 0.7, 0.65, 0.75 };
77 double w_0[
N_MODEL] = { -1.0, -0.9, -0.9, -0.9, -0.9 };
78 double w_a[
N_MODEL] = { 0.0, 0.0, 0.1, 0.1, 0.1 };
82 data->Omega_v[i] = Omega_v[i];
83 data->w_0[i] = w_0[i];
84 data->w_a[i] = w_a[i];
85 data->Omega_k[i] = 1.0 - data->Omega_c - data->Omega_b - data->Omega_v[i];
99 data->
w_0[model], data->
w_a[model],
101 -1,-1,-1,-1,NULL,NULL, &status);
108 for (
int i=0; i<
N_Z; i++) {
109 double a = 1/(1.+data->
z[i]);
114 if (fabs(absolute_tolerance)<1e-12) absolute_tolerance = 1e-12;
static void read_growth_test_file(const char *filename, double z[10], double gf[10][5])
size_t count(InputIterator first, InputIterator last, T const &item)
ccl_mnu_convention mnu_type
double ccl_growth_factor_unnorm(ccl_cosmology *cosmo, double a, int *status)
#define CTEST_SETUP(sname)
#define CTEST_DATA(sname)
ccl_cosmology * ccl_cosmology_create(ccl_parameters params, ccl_configuration config)
void ccl_cosmology_free(ccl_cosmology *cosmo)
#define ASSERT_DBL_NEAR_TOL(exp, real, tol)
const ccl_configuration default_config
#define ASSERT_EQUAL(exp, real)
#define ASSERT_NOT_NULL(real)
ccl_parameters ccl_parameters_create(double Omega_c, double Omega_b, double Omega_k, double Neff, double *mnu, ccl_mnu_convention mnu_type, double w0, double wa, double h, double norm_pk, double n_s, double bcm_log10Mc, double bcm_etab, double bcm_ks, int nz_mgrowth, double *zarr_mgrowth, double *dfarr_mgrowth, int *status)
#define CTEST2(sname, tname)
static void compare_growth(int model, struct growth_allz_data *data)