From 26961c0a0e52902d964b50c99d07bfbee268dbc3 Mon Sep 17 00:00:00 2001 From: Oliver Hahn Date: Wed, 8 Mar 2023 20:30:01 +0100 Subject: [PATCH] fixed bug that parameter was overwritten but not reread --- src/main.cc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/main.cc b/src/main.cc index 0c8a32f..214e735 100644 --- a/src/main.cc +++ b/src/main.cc @@ -452,9 +452,6 @@ int main(int argc, const char *argv[]) cf.insert_value("setup", "levelmin_TF", cf.get_value("setup", "levelmin")); } - // .. determine if spectral sampling should be used - const bool use_fourier_coarsening = cf.get_value_safe("setup", "fourier_splicing", true); - //------------------------------------------------------------------------------ //... initialize cosmology @@ -591,6 +588,9 @@ int main(int argc, const char *argv[]) poisson_plugin_creator *the_poisson_plugin_creator = get_poisson_plugin_map()[poisson_solver_name]; poisson_plugin *the_poisson_solver = the_poisson_plugin_creator->create(cf); + // .. this parameter needs to be read after the random module is initialised as it will be overwritten by it + const bool use_fourier_coarsening = cf.get_value_safe("setup", "fourier_splicing", true); + //--------------------------------------------------------------------------------- //... THIS IS THE MAIN DRIVER BRANCHING TREE RUNNING THE VARIOUS PARTS OF THE CODE //---------------------------------------------------------------------------------