PyBaMM icon indicating copy to clipboard operation
PyBaMM copied to clipboard

Domain degradation parameters

Open DrSOKane opened this issue 1 year ago • 3 comments

Description

Added domains to the SEI and plating degradation parameters, allowing them to be different on each electrode. This is useful for negative half-cells, where the positive electrode is graphite and the negative electrode is lithium metal.

  • The names of almost all SEI and plating parameters have been changed, making this a breaking change
  • All built-in parameter sets have been updated to work with the new syntax
  • The example notebook for half-cells has been updated to showcase the new feature. By adjusting the SEI parameters on each electrode, it is shown that SEI on the lithium metal electrode can provide enough resistance to prevent plating on the graphite electrode.
  • A parameter set for a half-cell with a graphite+silicon composite has been added. I considered adding this to the example notebook but it is already very long and I still don't have much experience using the composite model.

Type of change

Please add a line in the relevant section of CHANGELOG.md to document the change (include PR #) - note reverse order of PR #s. If necessary, also add to the list of breaking changes.

  • [x] New feature (non-breaking change which adds functionality)
  • [ ] Optimization (back-end change that speeds up the code)
  • [ ] Bug fix (non-breaking change which fixes an issue)

Key checklist:

  • [x] No style issues: $ pre-commit run (or $ nox -s pre-commit) (see CONTRIBUTING.md for how to set this up to run automatically when committing locally, in just two lines of code)
  • [ ] All tests pass: $ python run-tests.py --all (or $ nox -s tests)
  • [ ] The documentation builds: $ python run-tests.py --doctest (or $ nox -s doctests)

You can run integration tests, unit tests, and doctests together at once, using $ python run-tests.py --quick (or $ nox -s quick).

Further checks:

  • [ ] Code is commented, particularly in hard-to-understand areas
  • [ ] Tests added that prove fix is effective or that feature works

DrSOKane avatar Sep 24 '24 14:09 DrSOKane

Check out this pull request on  ReviewNB

See visual diffs & provide feedback on Jupyter Notebooks.


Powered by ReviewNB

Codecov Report

:x: Patch coverage is 58.19672% with 51 lines in your changes missing coverage. Please review. :white_check_mark: Project coverage is 99.23%. Comparing base (1b6ef03) to head (01ed5ed). :warning: Report is 567 commits behind head on develop.

Files with missing lines Patch % Lines
...ameters/lithium_ion/Chen2020_composite_halfcell.py 0.00% 51 Missing :warning:
Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #4463      +/-   ##
===========================================
- Coverage    99.46%   99.23%   -0.23%     
===========================================
  Files          293      294       +1     
  Lines        22384    22447      +63     
===========================================
+ Hits         22264    22276      +12     
- Misses         120      171      +51     

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

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

codecov[bot] avatar Sep 24 '24 17:09 codecov[bot]

This PR follows on from PR #4417 and does indeed contain everything from there. I've decided to convert this PR to draft and reopen when #4417 - which has far more use cases in practice - is complete.

DrSOKane avatar Sep 25 '24 12:09 DrSOKane

@DrSOKane Are you still working on this?

kratman avatar Jul 02 '25 17:07 kratman

@DrSOKane Are you still working on this?

Not recently. #4869 is much higher priority.

DrSOKane avatar Jul 03 '25 21:07 DrSOKane

Can we close this one for now, there are a huge number of conflicts

kratman avatar Jul 03 '25 22:07 kratman