diff --git a/CHANGELOG.md b/CHANGELOG.md index 5cd748f6984..dc2c2e0b934 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,7 @@ - [[PR564]](https://github.com/lanl/singularity-eos/pull/564) Removed Get() function from IndexableTypes since it could have unexpected consequences when a type wasn't present ### Fixed (Repair bugs, etc) +- [[PR567]](https://github.com/lanl/singularity-eos/pull/567) Fixed an OOB array access bug in the Fixed T PTE solver - [[PR561]](https://github.com/lanl/singularity-eos/pull/561) Fix logic for kokkos-kernels in spackage so that it is only required for closure models on GPU - [[PR563]](https://github.com/lanl/singularity-eos/pull/563) Fixed DensityFromPressureTemperature for the Carnahan-Starling EOS. - [[PR564]](https://github.com/lanl/singularity-eos/pull/564) Fix logic for numerical vs type indices by adding safeGet(), safeSet(), safeMustGet(), and safeMustSet() helpers diff --git a/singularity-eos/closure/mixed_cell_models.hpp b/singularity-eos/closure/mixed_cell_models.hpp index fecd8938f7f..c4b1238193d 100644 --- a/singularity-eos/closure/mixed_cell_models.hpp +++ b/singularity-eos/closure/mixed_cell_models.hpp @@ -1455,7 +1455,7 @@ class PTESolverFixedT Real error_p = 0; for (std::size_t m = 1; m < nmat; ++m) { mean_p += vfrac[m] * press[m]; - error_p += residual[m + 1] * residual[m + 1]; + error_p += residual[m] * residual[m]; } error_p = std::sqrt(error_p); Real error_v = std::abs(residual[0]);