diff --git a/include/openmc/settings.h b/include/openmc/settings.h index 74cbbc1328..ed9de630b2 100644 --- a/include/openmc/settings.h +++ b/include/openmc/settings.h @@ -45,6 +45,7 @@ extern "C" bool run_CE; //!< run with continuous-energy data? extern bool source_latest; //!< write latest source at each batch? extern bool source_separate; //!< write source to separate file? extern bool source_write; //!< write source in HDF5 files? +extern bool surface_source; //!< write surface source file? extern bool survival_biasing; //!< use survival biasing? extern bool temperature_multipole; //!< use multipole data? extern "C" bool trigger_on; //!< tally triggers enabled? diff --git a/src/settings.cpp b/src/settings.cpp index 5a868d445b..a4e294abf2 100644 --- a/src/settings.cpp +++ b/src/settings.cpp @@ -60,6 +60,7 @@ bool run_CE {true}; bool source_latest {false}; bool source_separate {false}; bool source_write {true}; +bool surface_source {false}; bool survival_biasing {false}; bool temperature_multipole {false}; bool trigger_on {false}; @@ -622,6 +623,11 @@ void read_settings_xml() sourcepoint_batch = statepoint_batch; } + // Check if the user has specified to write surface source. + if (check_for_node(root, "surface_source")) { + surface_source = get_node_value_bool(root, "surface_source"); + } + // If source is not seperate and is to be written out in the statepoint file, // make sure that the sourcepoint batch numbers are contained in the // statepoint list