pybamm-team / liionpack

A battery pack simulation tool that uses the PyBaMM framework
https://liionpack.readthedocs.io/en/latest/
MIT License
90 stars 30 forks source link

[Bug]: "Either-or condition" is not satisfied #290

Closed ihlas123 closed 6 months ago

ihlas123 commented 6 months ago

liionpack Version

0.3.7

Python Version

3.11.4

Describe the bug

I simulated an experiment with a battery combination of 1p1s. I used "Chen2020" as my parameter set. In the experiment protocol, I gave "Discharge at 5 A for 1 hour or until 3.3 V". As you can see in the document which I have attached, the voltage vs time graph passes beyond the 3.3 V without satisfying the "or" condition mentioned in the experiment protocol. This means that the solver is only accepting the 1st condition, in this case "discharge for 1 hour", but not the secondary condition "until 3.3 V".

Report.pdf

Steps to Reproduce

Report.pdf

Expected behaviour

If the experiment protocol contains "either-or" condition, the solver should satisfy any one of the condition. For example, in this case, "Discharge at 5 A for 1 hour or until 3.3 V", the experiment should conclude if the discharging process runs either for 1 hour or reaches 3.3 V.

Relevant log output

No response

Additional context

No response

TomTranter commented 6 months ago

Yeah sorry about this - only limited functionality is transferred from the experiment. I am tempted to remove the experiment altogether and force users to supply the protocol