Skip to content

Conversation

@mlouis9
Copy link

@mlouis9 mlouis9 commented Dec 23, 2025

Description

This feature adds a new setting for calculating subcritical multiplication factors in fixed source mode in a way analogous to eigenvalue mode. The relevant theory is contained in the added documentation, but this is generally useful for modeling accelerator driven systems. This involves:

  • Adding new global tally variables to store first generation fission production tallies in addition to the total fission production tallies accumulated across an entire history.
  • Adding new variables for storing multiplication factor averages, products, stddevs in simulation.cpp
  • Updating the statepoint writing to store calculated subcritical multiplication factors analogously to keff
  • Reusing code from eigenvalue.cpp for computing generation, average, and combined multiplication factor estimates
  • Updating statepoint.py to read statepoint files in a more permissive way using try-except rather than explicitly checking the run_mode for eigenvalues
  • Updating the logic in output.cpp to be slightly more generic and accept a different `eigenvalue_name
  • Since simulation::keff is used in this mode, needed to update physics.cpp to no longer weight nu_t by simulation::keff in calculate_subcritical_k mode.
  • Added a new source file and header subcritical.cpp, subcritical.h to contain necessary code for calculating kq. Major code duplication from eigenvalue.cpp, but was done in favor of generalizing code in eigenvalue.cpp and creating a much larger interface. This code is not expected to change anyways.
  • Added code for accumulating standard k estimates in fixed source mode
  • Added tests comparing with standard fixed source mode, and expected outputs. Perhaps a formal verification problem is needed.
  • Updated PyAPITestHarness to accept a generic results_true filename as an input argument, and a subcritical_k_results flag for adding subcritical k parameters to the results digest. Necessary for performing tests.

Checklist

  • I have performed a self-review of my own code
  • I have run clang-format (version 15) on any C++ source files (if applicable)
  • I have followed the style guidelines for Python source files (if applicable)
  • I have made corresponding changes to the documentation (if applicable)
  • I have added tests that prove my fix is effective or that my feature works (if applicable)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant