Repository navigation
Conversation
Reset the global citation state before checking defaults. This prevents earlier model construction from making the test depend on execution order.
Compare SEI thickness and lithium loss with the integrated growth law for SPM and DFN at two temperatures. Cover an experiment step change and continuation through starting_solution. Refs pybamm-team#6006.
lishi-01
marked this pull request as ready for review
October 31, 2026 02:55
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Refs #6006.
Analytical regression tests are added for solvent-diffusion-limited SEI growth. Film thickness and lithium loss are checked against the integrated growth law. An experiment step change and a new
Simulationusingstarting_solutionare covered.Four cases are tested: SPM and DFN at 298.15 K and 318.15 K. OKane2022 parameters and fixed reaction area are used. A non-unit lithium-to-SEI molar ratio is applied. This makes missing conversion factors detectable.
Expected values are calculated from the input parameters and geometry. The evaluated SEI current and RHS are not used. Values are compared at fixed absolute times through the interpolating solution interface.
A one-line reset is also added to the existing default-citations test. Its order dependency was reproduced on the earlier main baseline,
8c6816d27. Only two existing tests were needed. The reset gives that test the initial citation state it expects. This change can be reviewed independently of the SEI cases.The citation reset and the SEI regression tests are kept in separate commits.
Type of change
Tests only. No existing defect in the SEI growth equations is claimed.
Validation
Both test changes were replayed onto main commit
63476bc4951c1f91ec7b95f24fd3132dfe45550f. The tested branch head isce141e7b3215c4d0ea7bad3b932a80c11841d1ed. Ubuntu on WSL2 and Python 3.12.3 were used.The official solver wheel from main CI run 41065835434 was used. Its source commit matches this baseline. The installed native binary was checked against the wheel. The new shared CasADi and matrix-fill interfaces were present.
-W --keep-going, without warnings.The 47 unit and integration skips follow existing conditions:
Three doctest groups are explicitly marked with
+SKIP. No cases were skipped by the network precheck in this run.Earlier process-local mutation checks are described in #6006. An incorrect diffusion coefficient, a missing temperature factor and an incorrect stoichiometric factor were detected. Those checks predate this rebase. They assess mathematical implementation consistency under the stated assumptions.
Points for discussion
These cases use the default legacy experiment path. Feedback on unified-mode coverage and the test location is welcome, as discussed in #6006.