Skip to content

Make time-based heaviside and modulo inputs explicit t_eval points with IDAKLUSolver #4994

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 5 commits into
base: develop
Choose a base branch
from

Conversation

MarcBerliner
Copy link
Member

@MarcBerliner MarcBerliner commented Apr 24, 2025

Description

Fixed a bug where including inputs that had a heaviside or modulo as an explicit function of time would fail for the IDAKLUSolver. Now, these are added as explicit t_eval points to stop the solver during integration.

Requires pybamm-team/pybammsolvers#35

Type of change

Please add a line in the relevant section of CHANGELOG.md to document the change (include PR #)

Important checks:

Please confirm the following before marking the PR as ready for review:

  • No style issues: nox -s pre-commit
  • All tests pass: nox -s tests
  • The documentation builds: nox -s doctests
  • Code is commented for hard-to-understand areas
  • Tests added that prove fix is effective or that feature works

Copy link

codecov bot commented Apr 24, 2025

Codecov Report

Attention: Patch coverage is 81.25000% with 9 lines in your changes missing coverage. Please review.

Project coverage is 98.46%. Comparing base (cb17226) to head (97c36f4).
Report is 1 commits behind head on develop.

Files with missing lines Patch % Lines
src/pybamm/solvers/base_solver.py 80.00% 9 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #4994      +/-   ##
===========================================
- Coverage    98.57%   98.46%   -0.12%     
===========================================
  Files          304      304              
  Lines        23642    23677      +35     
===========================================
+ Hits         23306    23313       +7     
- Misses         336      364      +28     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

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