MP-Gadget
5.0.1.dev1-76bc7d4726-dirty
|
#include <stdarg.h>
#include <stddef.h>
#include <setjmp.h>
#include <cmocka.h>
#include <math.h>
#include <stdio.h>
#include <stdint.h>
#include <stdlib.h>
#include <libgadget/physconst.h>
#include <libgadget/cooling_rates.h>
#include <libgadget/config.h>
#include "stub.h"
Go to the source code of this file.
Macros | |
#define | NEXACT 20 |
Functions | |
int | during_helium_reionization (double redshift) |
double | recomb_alphaHp (double temp) |
static struct cooling_params | get_test_coolpar (void) |
static void | test_recomb_rates (void **state) |
static void | test_uvbg_loader (void **state) |
static void | test_rate_network (void **state) |
static void | test_heatingcooling_rate (void **state) |
int | main (void) |
Variables | |
static const double | f92g2 [NEXACT] = {5.758e-11, 2.909e-11, 1.440e-11, 6.971e-12,3.282e-12, 1.489e-12, 6.43e-13, 2.588e-13, 9.456e-14, 3.069e-14, 8.793e-15, 2.245e-15, 5.190e-16, 1.107e-16, 2.221e-17, 4.267e-18, 7.960e-19, 1.457e-19,2.636e-20, 4.737e-21} |
static const double | f92n1 [NEXACT] = {9.258e-12, 5.206e-12, 2.927e-12, 1.646e-12, 9.246e-13, 5.184e-13, 2.890e-13, 1.582e-13, 8.255e-14, 3.882e-14, 1.545e-14, 5.058e-15, 1.383e-15, 3.276e-16, 7.006e-17, 1.398e-17, 2.665e-18, 4.940e-19, 9.001e-20, 1.623e-20} |
static const double | tt [NEXACT] = {3.16227766e+00, 1.0e+01, 3.16227766e+01, 1.0e+02, 3.16227766e+02, 1.00e+03, 3.16227766e+03, 1.e+04, 3.16227766e+04, 1.e+05, 3.16227766e+05, 1.e+06, 3.16227766e+06, 1.0e+07, 3.16227766e+07, 1.0e+08, 3.16227766e+08, 1.0e+09, 3.16227766e+09, 1.0e+10} |
#define NEXACT 20 |
Definition at line 25 of file test_cooling_rates.c.
int during_helium_reionization | ( | double | redshift | ) |
Definition at line 18 of file test_cooling_rates.c.
|
static |
Definition at line 32 of file test_cooling_rates.c.
Referenced by test_heatingcooling_rate(), test_rate_network(), test_recomb_rates(), and test_uvbg_loader().
int main | ( | void | ) |
Definition at line 321 of file test_cooling_rates.c.
References test_heatingcooling_rate(), test_rate_network(), test_recomb_rates(), and test_uvbg_loader().
double recomb_alphaHp | ( | double | temp | ) |
Definition at line 347 of file cooling_rates.c.
References _Verner96Fit(), Badnell06, Cen92, CoolingParams, endrun(), cooling_params::recomb, and Verner96.
Referenced by cool_RecombHp(), init_cooling_rates(), nH0_internal(), recomb_alphaHepp(), and test_recomb_rates().
|
static |
Definition at line 174 of file test_cooling_rates.c.
References Cen92, cooling_params::cooling, cooling_units::CoolingOn, coolunits, CP, cooling_units::density_in_phys_cgs, UVBG::epsHep, cooling_params::fBar, get_global_UVBG(), get_heatingcooling_rate(), get_test_coolpar(), UVBG::gJHe0, Cosmology::HubbleParam, HYDROGEN_MASSFRAC, init_cooling_rates(), KWH92, MetalCool, Cosmology::OmegaBaryon, Cosmology::OmegaCDM, PROTONMASS, cooling_params::recomb, cooling_params::SelfShieldingOn, set_coolpar(), cooling_units::tt_in_s, UnitLength_in_cm, and cooling_units::uu_in_cgs.
Referenced by main().
|
static |
Definition at line 119 of file test_cooling_rates.c.
References CP, cooling_params::fBar, get_equilib_ne(), get_global_UVBG(), get_neutral_fraction_phys_cgs(), get_temp(), get_test_coolpar(), Cosmology::HubbleParam, init_cooling_rates(), MetalCool, Cosmology::OmegaBaryon, Cosmology::OmegaCDM, cooling_params::SelfShieldingOn, and set_coolpar().
Referenced by main().
|
static |
Definition at line 52 of file test_cooling_rates.c.
References Cen92, CP, f92g2, f92n1, cooling_params::fBar, get_test_coolpar(), Cosmology::HubbleParam, init_cooling_rates(), MetalCool, NEXACT, Cosmology::OmegaBaryon, Cosmology::OmegaCDM, cooling_params::recomb, recomb_alphaHp(), set_coolpar(), and tt.
Referenced by main().
|
static |
Definition at line 80 of file test_cooling_rates.c.
References CP, UVBG::epsH0, UVBG::epsHe0, UVBG::epsHep, cooling_params::fBar, get_global_UVBG(), get_test_coolpar(), UVBG::gJH0, UVBG::gJHe0, UVBG::gJHep, Cosmology::HubbleParam, init_cooling_rates(), MetalCool, Cosmology::OmegaBaryon, Cosmology::OmegaCDM, UVBG::self_shield_dens, cooling_params::SelfShieldingOn, and set_coolpar().
Referenced by main().
|
static |
Definition at line 29 of file test_cooling_rates.c.
Referenced by test_recomb_rates().
|
static |
Definition at line 31 of file test_cooling_rates.c.
Referenced by test_recomb_rates().
|
static |
Definition at line 32 of file test_cooling_rates.c.
Referenced by init_cooling_rates(), and test_recomb_rates().