Fast Methods for Cosmological Simulations
FastSim serves as a tool for quick N-body simulations in modified gravity.
ccl_test_cosmology.c File Reference
#include "ccl.h"
#include "ctest.h"
Include dependency graph for ccl_test_cosmology.c:

Go to the source code of this file.

Classes

struct  cosmology_data
 

Functions

void __attribute__ ((weak))
 
void __ctest_cosmology_create_general_cosmo_run (struct cosmology_data *data)
 

Variables

static struct cosmology_data __ctest_cosmology_data
 

Function Documentation

void __attribute__ ( (weak)  )

Definition at line 26 of file ccl_test_cosmology.c.

References ccl_mnu_sum.

26  {
27  data->Omega_c = 0.25;
28  data->Omega_b = 0.05;
29  data->Omega_k = 0.00;
30  data->h = 0.7;
31  data->A_s = 2.1e-9;
32  data->n_s = 0.96;
33  data->wa = 0.01;
34  data->w0 = -1.0;
35  data->Neff = 0.;
36  data->mnuval =0.;
37  data->status=0;
38  data->mnu_type =ccl_mnu_sum;
39 }
void __ctest_cosmology_create_general_cosmo_run ( struct cosmology_data data)

Definition at line 42 of file ccl_test_cosmology.c.

42  {
45  data->Omega_c, data->Omega_b, data->h, data->A_s, data->n_s,
46  &(data->status));
47 
48  // Initialize ccl_cosmology struct
49  ccl_cosmology * cosmo = ccl_cosmology_create(params, config);
50 
51  // test a few critical things
52  ASSERT_EQUAL(cosmo->status, 0);
53  ASSERT_DBL_NEAR_TOL(cosmo->data.growth0, 1., 1e-10);
54 }
double growth0
Definition: ccl_core.h:81
ccl_cosmology * ccl_cosmology_create(ccl_parameters params, ccl_configuration config)
Definition: ccl_core.c:173
dictionary params
Definition: halomod_bm.py:27
#define ASSERT_DBL_NEAR_TOL(exp, real, tol)
Definition: ctest.h:152
const ccl_configuration default_config
Definition: ccl_core.c:21
#define ASSERT_EQUAL(exp, real)
Definition: ctest.h:121
ccl_parameters ccl_parameters_create_flat_lcdm(double Omega_c, double Omega_b, double h, double norm_pk, double n_s, int *status)
Definition: ccl_core.c:505
ccl_data data
Definition: ccl_core.h:126

Variable Documentation

struct cosmology_data __ctest_cosmology_data
static

Definition at line 42 of file ccl_test_cosmology.c.