Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Determine whether nuclides are fissionable in volume calc mode #3047

Merged
merged 3 commits into from
Jun 20, 2024

Conversation

paulromano
Copy link
Contributor

@paulromano paulromano commented Jun 19, 2024

Description

This PR fixes a potential issue in sampling external source sites when OpenMC is loaded in volume calculation mode (which is used by the plotter). When running in volume calculation mode, we only load a select few attributes from nuclide .h5 files. Right now, we don't determine whether a nuclide is fissionable. However, for a proposed improvement to our plotter (see openmc-dev/plotter#131), it will be possible to sampling external source sites, which may require information on whether a material is fissionable if the "fissionable only" constraint is applied to the source. Without that information, a source with the "fissionable only" constraint will always be rejected because it won't think any material is fissionable (because the underlying nuclides aren't fissionable). This branch adds a small block of logic to determine if a nuclide is fissionable when it is loaded in volume calculation mode.

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)

@paulromano paulromano requested a review from pshriwise June 19, 2024 21:11
@paulromano paulromano added this to the v0.15.0 milestone Jun 19, 2024
Copy link
Contributor

@pshriwise pshriwise left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tiny suggestion here and then I think this should be good. Thanks @paulromano!

src/nuclide.cpp Outdated Show resolved Hide resolved
Copy link
Contributor

@pshriwise pshriwise left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @paulromano!

@pshriwise pshriwise merged commit 78ee851 into openmc-dev:develop Jun 20, 2024
16 checks passed
@paulromano paulromano deleted the volume-calc-fissionable branch June 20, 2024 14:35
church89 pushed a commit to openmsr/openmc that referenced this pull request Jul 18, 2024
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.

2 participants