mirror of
https://github.com/openmc-dev/openmc.git
synced 2026-07-27 13:45:36 -04:00
mcpl-file output simimlar to regular source output file
This commit is contained in:
parent
94fb5f8fa6
commit
81fa3b45a3
3 changed files with 16 additions and 0 deletions
|
|
@ -47,6 +47,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 source_mcpl_write; //!< write source in mcpl files?
|
||||
extern bool surf_source_write; //!< write surface source file?
|
||||
extern bool surf_mcpl_write; //!< write surface mcpl file?
|
||||
extern bool surf_source_read; //!< read surface source file?
|
||||
|
|
|
|||
|
|
@ -60,6 +60,7 @@ bool run_CE {true};
|
|||
bool source_latest {false};
|
||||
bool source_separate {false};
|
||||
bool source_write {true};
|
||||
bool source_mcpl_write {true};
|
||||
bool surf_source_write {false};
|
||||
bool surf_mcpl_write {false};
|
||||
bool surf_source_read {false};
|
||||
|
|
|
|||
|
|
@ -399,6 +399,20 @@ void finalize_batch()
|
|||
auto filename = settings::path_output + "source.h5";
|
||||
write_source_point(filename.c_str());
|
||||
}
|
||||
|
||||
#ifdef OPENMC_MCPL
|
||||
if (contains(settings::sourcepoint_batch, simulation::current_batch) &&
|
||||
settings::source_mcpl_write && settings::source_separate) {
|
||||
write_mcpl_source_point(nullptr);
|
||||
}
|
||||
|
||||
// Write a continously-overwritten source point if requested.
|
||||
if (settings::source_latest && setting::source_mcpl_write) {
|
||||
auto filename = settings::path_output + "source.mcpl";
|
||||
write_mcpl_source_point(filename.c_str());
|
||||
}
|
||||
#endif
|
||||
|
||||
}
|
||||
|
||||
// Write out surface source if requested.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue