openmc icon indicating copy to clipboard operation
openmc copied to clipboard

Delayed neutron fraction by isotope with IFP method

Open OlivaresDarian opened this issue 1 month ago • 12 comments

Description

This modification allows the Iterated Fission Probability (IFP) method implemented by @JoffreyDorville to break down the effective delayed neutron fraction $\beta_{eff}$ tally by isotope. This extension of the IFP method enables deeper analyses in reactor physics.

In practice, the IFP tally stores certain ancestor information to compute adjoint-weighted tallies. This adaptation follows the same principle but also records the isotope that generated each delayed neutron. It slightly increases both memory use and computation time.

To use it, you simply need to define a list of nuclides in $\texttt{beta-num-tally.nuclides = [...]}$.

Fixes #3605

Checklist

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

OlivaresDarian avatar Nov 26 '25 16:11 OlivaresDarian

You should run clang format (version 15) on cpp source files for CI to successfully run.

GuySten avatar Nov 27 '25 11:11 GuySten

You should run clang format (version 15) on cpp source files for CI to successfully run.

Thanks @GuySten for your help

OlivaresDarian avatar Nov 27 '25 13:11 OlivaresDarian

I think you accidentally removed src/output.cpp and its header. You should watch closely the "files changed" tab of this PR. A change in 47 files seems too much for a feature of this scope.

GuySten avatar Nov 27 '25 16:11 GuySten

I think you accidentally removed src/output.cpp and its header. You should watch closely the "files changed" tab of this PR. A change in 47 files seems too much for a feature of this scope.

You're right. I already restored the output.* files. From the 47 changes, more than 27 are related to tests modifications because we added a new variable to the Particle object. The current version passes all tests in local.

OlivaresDarian avatar Nov 28 '25 10:11 OlivaresDarian

But you also added new files (I think by mistake). Edit: You can find them by the green plus in the files tab of this PR.

GuySten avatar Nov 28 '25 10:11 GuySten

Thanks again, @GuySten, for your corrections and comments. This is my first PR to incorporate changes into OpenMC, so I apologize for any errors in my first version.

OlivaresDarian avatar Dec 01 '25 09:12 OlivaresDarian

@paulromano, I am tagging you because you asked to be tagged in PRs that affect performance. I think this PR will affect performance in some way because we increase the size of the SourceSite structure.

GuySten avatar Dec 01 '25 15:12 GuySten

I've added python api to improve the accessibility of this feature.

GuySten avatar Dec 04 '25 12:12 GuySten

While trying to fix the current failing tests, I found a bug. I will update this PR after #3676 is merged.

GuySten avatar Dec 09 '25 20:12 GuySten

Thanks @OlivaresDarian and @GuySten for this new feature! I would also like to take a look at it before we merge.

JoffreyDorville avatar Dec 09 '25 21:12 JoffreyDorville

I think a nice follow up feature will be to sample more frequently delayed neutrons with lower weight. This should help the convergence of the kinetic parameters.

@JoffreyDorville, @OlivaresDarian, what do you think?

GuySten avatar Dec 09 '25 22:12 GuySten

My bad, I thought that was a typo. I fixed it in the last commit.

GuySten avatar Dec 10 '25 16:12 GuySten