Skip to content

Comments

Enable "hybrid" tallies in get_microxs_and_flux#3831

Open
paulromano wants to merge 5 commits intoopenmc-dev:developfrom
paulromano:microxs-hybrid
Open

Enable "hybrid" tallies in get_microxs_and_flux#3831
paulromano wants to merge 5 commits intoopenmc-dev:developfrom
paulromano:microxs-hybrid

Conversation

@paulromano
Copy link
Contributor

Description

Currently, the get_microxs_and_flux function has two methods for computing cross sections: either using direct reaction rate tallies or tallying a flux spectrum and then collapsing a one-group reaction rate. This PR adds a reaction_rate_opts keyword argument to that enables a hybrid approach. When reaction_rate_mode='flux', users can now specify a subset of nuclide/reaction pairs via reaction_rate_opts to be computed via direct reaction-rate tallies rather than flux collapse. The directly-tallied values take precedence over flux-collapsed values for those pairs in the returned MicroXS objects. A new MicroXS.merge() method supports combining the two sets of results.

This mirrors the hybrid tally capability already available in the coupled depletion operator, making it accessible when using IndependentOperator with get_microxs_and_flux.

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