pybamm-team / PyBaMM

Fast and flexible physics-based battery models in Python
https://www.pybamm.org/
BSD 3-Clause "New" or "Revised" License
1.11k stars 546 forks source link

Compatibility problem of LFP parameter set with DFN Model. #4551

Open ALMA7867 opened 1 day ago

ALMA7867 commented 1 day ago

When I am simulating DFN model with LFP Prada2013 parameter set showing the error of "At t = 222.02 and h = 1.54123e-18, the corrector convergence failed repeatedly or with |h| = hmin. At t = 222.02 and h = 1.24251e-13, the corrector convergence failed repeatedly or with |h| = hmin."

So, I am not sure what to change with Prada parameter set to work with DFN model.

kratman commented 1 day ago

Hi @ALMA7867, This is more of an informative message from the equation solver than an actual issue. Optimization algorithms often have to try a direction, then back track if it does not work (i.e. line searches) or adjust time steps to reduce errors in the solution. The CasADI solver with our default logging settings produces a lot of output like what you are seeing.

If you feel that the messages are interfering with your work flow then you can

  1. Change the logging level to only show errors
  2. Switch to the IDAKLU solver which is a bit faster and prints fewer warnings