Skip to content

Refactor form_matrix method on depletion chain class#3892

Open
eepeterson wants to merge 1 commit intoopenmc-dev:developfrom
eepeterson:refactor_form_matrix
Open

Refactor form_matrix method on depletion chain class#3892
eepeterson wants to merge 1 commit intoopenmc-dev:developfrom
eepeterson:refactor_form_matrix

Conversation

@eepeterson
Copy link
Contributor

Description

This PR breaks up the responsibilities of the form_matrix method into separate methods - one for decay and one for the reaction rates. The decay matrix can be created once and cached on the chain so it doesn't need to be recomputed for every material for every step and/or stage in higher order integration schemes. While this provides no real performance benefit by itself yet, it enables other modifications that do and generally improves the separation of responsibility in the depletion module.

Fixes # (issue)
N/A

Checklist

  • I have performed a self-review of my own code
  • I have run clang-format (version 18) 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)

@eepeterson eepeterson requested a review from paulromano as a code owner March 20, 2026 04:17
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