From 0f429e7ea739edf26e8798c2cd670d632dc3a997 Mon Sep 17 00:00:00 2001 From: Ethan Peterson Date: Mon, 25 Sep 2023 17:25:37 -0400 Subject: [PATCH] simplifying LEQI docstring math and removing unnecessary operations (#2705) --- openmc/deplete/_matrix_funcs.py | 2 +- openmc/deplete/integrators.py | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/openmc/deplete/_matrix_funcs.py b/openmc/deplete/_matrix_funcs.py index a606d739f7..c7f7df76fb 100644 --- a/openmc/deplete/_matrix_funcs.py +++ b/openmc/deplete/_matrix_funcs.py @@ -77,4 +77,4 @@ def leqi_f4(chain, inputs, fission_yields=None): return (-dt ** 2 / (12 * dt_l * (dt + dt_l)) * f1 + (dt ** 2 + 2 * dt * dt_l + dt_l ** 2) / (12 * dt_l * (dt + dt_l)) * f2 - + (4 * dt * dt_l + 5 * dt_l ** 2) / (12 * dt_l * (dt + dt_l)) * f3) + + (4 * dt + 5 * dt_l) / (12 * (dt + dt_l)) * f3) diff --git a/openmc/deplete/integrators.py b/openmc/deplete/integrators.py index d17105fc70..a877c4900f 100644 --- a/openmc/deplete/integrators.py +++ b/openmc/deplete/integrators.py @@ -360,8 +360,7 @@ class LEQIIntegrator(Integrator): h_i)} \mathbf{A}_0 + \frac{h_{i-1}}{12 (h_{i-1} + h_i)} \mathbf{A}_1 \\ \mathbf{F}_4 &= \frac{-h_i^2}{12 h_{i-1} (h_{i-1} + h_i)} \mathbf{A}_{-1} + \frac{h_{i-1}^2 + 2 h_i h_{i-1} + h_i^2}{12 h_{i-1} (h_{i-1} + h_i)} - \mathbf{A}_0 + \frac{5 h_{i-1}^2 + 4 h_i h_{i-1}}{12 h_{i-1} - (h_{i-1} + h_i)} \mathbf{A}_1 \\ + \mathbf{A}_0 + \frac{5 h_{i-1} + 4 h_i}{12 (h_{i-1} + h_i)} \mathbf{A}_1 \\ \mathbf{n}_{i+1} &= \exp(h_i \mathbf{F}_4) \exp(h_i \mathbf{F}_3) \mathbf{n}_i \end{aligned}