Skip to content

Commit

Permalink
Merge pull request #360 from LSSTDESC/fix_cmblens_spline_reset
Browse files Browse the repository at this point in the history
Fixes re-setting of spline parameters in ccl_test_cmblens.c
  • Loading branch information
elisachisari committed Apr 3, 2018
2 parents 194eff2 + ac8fcf3 commit 4cd7906
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions tests/ccl_test_cmblens.c
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,9 @@ static void compare_cls(struct cls_data * data)
ASSERT_NOT_NULL(cosmo);

//Fix spline parameters for the high-redshift needs of the CMB lensing power spectrum
//We save them first to restore them to their usual values at the end.
int na_sv=ccl_splines->A_SPLINE_NA;
int na_pk_sv=ccl_splines->A_SPLINE_NA_PK;
ccl_splines->A_SPLINE_NA=10000;
ccl_splines->A_SPLINE_NA_PK=500;

Expand All @@ -81,6 +84,8 @@ static void compare_cls(struct cls_data * data)
printf("%lf %% ",fraction_failed*100);
ASSERT_TRUE((fraction_failed<CLS_FRACTION));

ccl_splines->A_SPLINE_NA=na_sv;
ccl_splines->A_SPLINE_NA_PK=na_pk_sv;
ccl_cl_tracer_free(tr_cl);
ccl_cosmology_free(cosmo);
}
Expand Down

0 comments on commit 4cd7906

Please sign in to comment.