# PyBaMM Q&A

**URL:** https://pybamm.discourse.group/c/pybamm-qa/6.md?page=1

[Latest](https://pybamm.discourse.group/latest.md) · [Categories](https://pybamm.discourse.group/categories.md) · [Tags](https://pybamm.discourse.group/tags.md)

**Page:** 2

---

## [Heat Transfer Coefficient Only Affects Temperature, Not Current/Voltage/Power](https://pybamm.discourse.group/t/heat-transfer-coefficient-only-affects-temperature-not-current-voltage-power/366)

<div class="topic-metadata">

**Author:** [@Maguixx](https://pybamm.discourse.group/u/Maguixx)\
**Replies:** 1\
**Last updated:** [5 September 2025 14:46 UTC](https://pybamm.discourse.group/t/heat-transfer-coefficient-only-affects-temperature-not-current-voltage-power/366 "2025-09-05T14:46:46Z")

</div>

Issue Description I performed two discharge simulations with different heat transfer coefficient values (10 and 290) and noticed that only the temperature profile changes between the two cases. The current, voltage, resi…

---

## [Hysteresis in ECM model?](https://pybamm.discourse.group/t/hysteresis-in-ecm-model/387)

<div class="topic-metadata">

**Author:** [@lefile](https://pybamm.discourse.group/u/lefile)\
**Replies:** 0\
**Last updated:** [26 August 2025 11:54 UTC](https://pybamm.discourse.group/t/hysteresis-in-ecm-model/387 "2025-08-26T11:54:20Z")

</div>

Hi Everyone! Just a quick question - can I use hysteresis sub-model within equivalent-circuit model? I’d like to define charge and discharge OCVs. Best regards!

---

## [SOH with Drive Cycle Profiles with Coupled Degradation Models](https://pybamm.discourse.group/t/soh-with-drive-cycle-profiles-with-coupled-degradation-models/383)

<div class="topic-metadata">

**Author:** [@AkilaJ](https://pybamm.discourse.group/u/AkilaJ)\
**Replies:** 0\
**Last updated:** [18 August 2025 16:19 UTC](https://pybamm.discourse.group/t/soh-with-drive-cycle-profiles-with-coupled-degradation-models/383 "2025-08-18T16:19:36Z")

</div>

Hi All and @DrSOKane I am trying to use the coupled degradation model for drive cycle simulations. As a start, I wanted to use the US06 drive cycle with the coupled degradation models and obtain capacity (or SOH) vari…

---

## [Where to obtain parameter for the x-full thermal model](https://pybamm.discourse.group/t/where-to-obtain-parameter-for-the-x-full-thermal-model/375)

<div class="topic-metadata">

**Author:** [@alighato](https://pybamm.discourse.group/u/alighato)\
**Replies:** 0\
**Last updated:** [6 August 2025 18:33 UTC](https://pybamm.discourse.group/t/where-to-obtain-parameter-for-the-x-full-thermal-model/375 "2025-08-06T18:33:39Z")

</div>

I am struggling to understand how I would go about getting parameters for this model. I haven’t found a parameter example set in the repo, and also could not map these parameters: 'Negative current collector surface hea…

---

## ['Event exceeded in initial conditions' error with step charging experiment](https://pybamm.discourse.group/t/event-exceeded-in-initial-conditions-error-with-step-charging-experiment/371)

<div class="topic-metadata">

**Author:** [@Thiyaga](https://pybamm.discourse.group/u/Thiyaga)\
**Replies:** 0\
**Last updated:** [1 August 2025 11:05 UTC](https://pybamm.discourse.group/t/event-exceeded-in-initial-conditions-error-with-step-charging-experiment/371 "2025-08-01T11:05:09Z")

</div>

Greetings team PYBAMM, I am doing a step charging experiment with pybamm and face numerical issues i.e. Experiment is infeasible: ‘Event exceeded in initial conditions’ error. I apply a step charging protocol with volt…

---

## [Passing initial soc and starting solution together](https://pybamm.discourse.group/t/passing-initial-soc-and-starting-solution-together/359)

<div class="topic-metadata">

**Author:** [@harisankarsuresh](https://pybamm.discourse.group/u/harisankarsuresh)\
**Replies:** 0\
**Last updated:** [30 June 2025 09:54 UTC](https://pybamm.discourse.group/t/passing-initial-soc-and-starting-solution-together/359 "2025-06-30T09:54:34Z")

</div>

If i pass initial\_soc and starting\_solution into of sim.solve which has been run using experiments, will the initial soc be overwritten from starting solution? sim.solve( solver=safe\_solver, …

---

## [Installing SEI and LAM degradation models for PyBaMM 25.6.0](https://pybamm.discourse.group/t/installing-sei-and-lam-degradation-models-for-pybamm-25-6-0/353)

<div class="topic-metadata">

**Author:** [@MGG](https://pybamm.discourse.group/u/MGG)\
**Replies:** 1\
**Last updated:** [22 June 2025 18:18 UTC](https://pybamm.discourse.group/t/installing-sei-and-lam-degradation-models-for-pybamm-25-6-0/353 "2025-06-22T18:18:47Z")

</div>

Hello, all. I have installed PyBaMM 26.5.0 on windows using PIP installer. But DFN degradation appears to be limited to the SEIgrowth model, and high cycle simulations so far are insensitive to cell temperature - clea…

---

## [Adding a new field equation to DFN: coupling mechanics with electrochemistry](https://pybamm.discourse.group/t/adding-a-new-field-equation-to-dfn-coupling-mechanics-with-electrochemistry/351)

<div class="topic-metadata">

**Author:** [@kze](https://pybamm.discourse.group/u/kze)\
**Replies:** 0\
**Last updated:** [20 June 2025 09:49 UTC](https://pybamm.discourse.group/t/adding-a-new-field-equation-to-dfn-coupling-mechanics-with-electrochemistry/351 "2025-06-20T09:49:24Z")

</div>

Hi all, I’m trying to add a custom equation to the existing DFN model in PyBaMM, but I’m struggling to figure out how to properly integrate it into the framework so that it’s solved simultaneously with the rest of the m…

---

## [Significant differences between IDAKLU and Casadi solutions](https://pybamm.discourse.group/t/significant-differences-between-idaklu-and-casadi-solutions/348)

<div class="topic-metadata">

**Author:** [@isaac\_basil](https://pybamm.discourse.group/u/isaac_basil)\
**Replies:** 0\
**Last updated:** [16 June 2025 17:02 UTC](https://pybamm.discourse.group/t/significant-differences-between-idaklu-and-casadi-solutions/348 "2025-06-16T17:02:18Z")

</div>

Hi, I’ve encountered some concerning problems using the IDAKLU solver recently. I am coding a new model, as described in this paper. When I solve it using the Casadi solver, results look great. However, when I change to…

---

## [Difference between 'Formation capacity loss \[A.h\]' and 'Loss of capacity to negative SEI \[A.h\]',](https://pybamm.discourse.group/t/difference-between-formation-capacity-loss-a-h-and-loss-of-capacity-to-negative-sei-a-h/347)

<div class="topic-metadata">

**Author:** [@J-Py](https://pybamm.discourse.group/u/J-Py)\
**Replies:** 0\
**Last updated:** [16 June 2025 16:18 UTC](https://pybamm.discourse.group/t/difference-between-formation-capacity-loss-a-h-and-loss-of-capacity-to-negative-sei-a-h/347 "2025-06-16T16:18:07Z")

</div>

Hi, I am running a degradation sim with the O’Kane model with the following models: sei\_growth=“solvent-diffusion limited”, lithium\_plating=“partially reversible”, loss\_active\_material=stress-driven", porosity\_chang…

---

## [Sim.plot() doesn't seem to work for 1D variables of the BaseModel Class](https://pybamm.discourse.group/t/sim-plot-doesnt-seem-to-work-for-1d-variables-of-the-basemodel-class/343)

<div class="topic-metadata">

**Author:** [@42Nachos](https://pybamm.discourse.group/u/42Nachos)\
**Replies:** 0\
**Last updated:** [16 June 2025 06:35 UTC](https://pybamm.discourse.group/t/sim-plot-doesnt-seem-to-work-for-1d-variables-of-the-basemodel-class/343 "2025-06-16T06:35:25Z")

</div>

Hi, I’ve been trying to experiment with building models from scratch using the PyBaMM.BaseModel class. However, I am unable to plot 1D variables this way. My model is shared below here: import pybamm class model(pyba…

---

## [Error when multiplying with an interpolant](https://pybamm.discourse.group/t/error-when-multiplying-with-an-interpolant/292)

<div class="topic-metadata">

**Author:** [@isaac\_basil](https://pybamm.discourse.group/u/isaac_basil)\
**Replies:** 5\
**Last updated:** [29 May 2025 08:16 UTC](https://pybamm.discourse.group/t/error-when-multiplying-with-an-interpolant/292 "2025-05-29T08:16:51Z")

</div>

Hi, I posted a previous question on a similar (but not identical) topic. However the problem here is much more refined, so I may delete the previous one. I am getting an error when I take the product of an interpolant …

---

## [Modifying experiment without rebuilding sim](https://pybamm.discourse.group/t/modifying-experiment-without-rebuilding-sim/327)

<div class="topic-metadata">

**Author:** [@senzhan](https://pybamm.discourse.group/u/senzhan)\
**Replies:** 0\
**Last updated:** [15 May 2025 12:48 UTC](https://pybamm.discourse.group/t/modifying-experiment-without-rebuilding-sim/327 "2025-05-15T12:48:42Z")

</div>

I read that you can modify the current function without rebuilding the simulation again. This saves a lot of time when you need to run a series of simulations. Is there a way to modify experiment without rebuilding simul…

---

## [Discrepancy in Discharge Capacity Between Chen2020 and Mohtat2020 Parameter Sets Despite Aligned Key Parameters](https://pybamm.discourse.group/t/discrepancy-in-discharge-capacity-between-chen2020-and-mohtat2020-parameter-sets-despite-aligned-key-parameters/320)

<div class="topic-metadata">

**Author:** [@vipulnovo](https://pybamm.discourse.group/u/vipulnovo)\
**Replies:** 1\
**Last updated:** [8 May 2025 10:05 UTC](https://pybamm.discourse.group/t/discrepancy-in-discharge-capacity-between-chen2020-and-mohtat2020-parameter-sets-despite-aligned-key-parameters/320 "2025-05-08T10:05:51Z")

</div>

Hello PyBaMM community, I’ve been conducting simulations using both the Chen2020 and Mohtat2020 parameter sets. To ensure consistency, I’ve aligned several key parameters across both sets, including: Maximum and initi…

---

## [Accelerating SEI Formation](https://pybamm.discourse.group/t/accelerating-sei-formation/319)

<div class="topic-metadata">

**Author:** [@AlasdairCrawford](https://pybamm.discourse.group/u/AlasdairCrawford)\
**Replies:** 0\
**Last updated:** [1 May 2025 23:31 UTC](https://pybamm.discourse.group/t/accelerating-sei-formation/319 "2025-05-01T23:31:54Z")

</div>

Hello, I want to be able to simulate one cycle to represent multiple ageing cycles (For example to simulate a battery aging over 800 cycles, I might only simulate 8 cycles with ageing factor of 100). For reference, this…

---

## [Is it possible to pass voltage as an input to sim.step()](https://pybamm.discourse.group/t/is-it-possible-to-pass-voltage-as-an-input-to-sim-step/308)

<div class="topic-metadata">

**Author:** [@ErfanSamadi1998](https://pybamm.discourse.group/u/ErfanSamadi1998)\
**Replies:** 3\
**Last updated:** [27 April 2025 18:52 UTC](https://pybamm.discourse.group/t/is-it-possible-to-pass-voltage-as-an-input-to-sim-step/308 "2025-04-27T18:52:17Z")

</div>

Hi, I am currently using pybamm.Simulation.step() to run a DFN model step-by-step with current as an input. Here’s my minimal working example: import pybamm options = {"thermal": "lumped"} model = pybamm.lithium\_ion.D…

---

## [Failed for getting results after some cyclings](https://pybamm.discourse.group/t/failed-for-getting-results-after-some-cyclings/311)

<div class="topic-metadata">

**Author:** [@FrankW9997](https://pybamm.discourse.group/u/FrankW9997)\
**Replies:** 1\
**Last updated:** [23 April 2025 13:35 UTC](https://pybamm.discourse.group/t/failed-for-getting-results-after-some-cyclings/311 "2025-04-23T13:35:55Z")

</div>

Hi, I’m new to PyBaMM and I want to design an experiment to record my charging and discharging results. However, some results showed as None, I don’t know why. I’ve attached my codes. import pybamm experiment = pybamm…

---

## [Compatibility Issue with SEI on Cracks in Composite Model](https://pybamm.discourse.group/t/compatibility-issue-with-sei-on-cracks-in-composite-model/307)

<div class="topic-metadata">

**Author:** [@Hesam\_Tavakoli](https://pybamm.discourse.group/u/Hesam_Tavakoli)\
**Replies:** 0\
**Last updated:** [19 April 2025 19:06 UTC](https://pybamm.discourse.group/t/compatibility-issue-with-sei-on-cracks-in-composite-model/307 "2025-04-19T19:06:14Z")

</div>

Hi, I’ve encountered an issue while working with PyBaMM, specifically with the SEI on cracks model when used in conjunction with a composite model. The following error was raised: KeyError: "'X-averaged negative partic…

---

## [Extracting timestamp for each experimental step](https://pybamm.discourse.group/t/extracting-timestamp-for-each-experimental-step/305)

<div class="topic-metadata">

**Author:** [@J-Py](https://pybamm.discourse.group/u/J-Py)\
**Replies:** 0\
**Last updated:** [18 April 2025 08:29 UTC](https://pybamm.discourse.group/t/extracting-timestamp-for-each-experimental-step/305 "2025-04-18T08:29:56Z")

</div>

Hi everyone, is there a method to extract a timestamp for each step of the pybamm.experiment, once the sim has finished running , i.e. I would like to extract the start and end time of a specific step in a cycle? e.g. …

---

## [Changing Stoichiometry of Individual Electrodes](https://pybamm.discourse.group/t/changing-stoichiometry-of-individual-electrodes/192)

<div class="topic-metadata">

**Author:** [@vipulnovo](https://pybamm.discourse.group/u/vipulnovo)\
**Replies:** 3\
**Last updated:** [15 April 2025 13:18 UTC](https://pybamm.discourse.group/t/changing-stoichiometry-of-individual-electrodes/192 "2025-04-15T13:18:08Z")

</div>

Hi everyone, I was wondering if it’s possible to change the stoichiometry of individual electrodes in PyBaMM. Specifically, I’m looking to adjust the stoichiometry for the anode and cathode independently. Is there a way…

---

## [Tutorial 1 - How to run a model plotting function](https://pybamm.discourse.group/t/tutorial-1-how-to-run-a-model-plotting-function/302)

<div class="topic-metadata">

**Author:** [@piercarmine](https://pybamm.discourse.group/u/piercarmine)\
**Replies:** 2\
**Last updated:** [11 April 2025 06:54 UTC](https://pybamm.discourse.group/t/tutorial-1-how-to-run-a-model-plotting-function/302 "2025-04-11T06:54:32Z")

</div>

Hi all! I tried running the Tutorial 1 notebook on a fresh PyBamm installation, but I am getting an error upon plotting with sim.plot(), as the most recent version of scipy does not have an interp2d function anymore. I…

---

## [Export Pybamm equations to Matlab / Simulink via Casadi: Temperature input not working](https://pybamm.discourse.group/t/export-pybamm-equations-to-matlab-simulink-via-casadi-temperature-input-not-working/251)

<div class="topic-metadata">

**Author:** [@mo\_pb](https://pybamm.discourse.group/u/mo_pb)\
**Replies:** 1\
**Last updated:** [10 April 2025 10:41 UTC](https://pybamm.discourse.group/t/export-pybamm-equations-to-matlab-simulink-via-casadi-temperature-input-not-working/251 "2025-04-10T10:41:25Z")

</div>

I would like to export the Pybamm equations as Casadi objects and solve them in Matlab. The code attached is mostly based on this example GitHub - FaradayInstitution/pybamm\_simulink\_example: An example of how to run py…

---

## [Lumped Thermal Model - Can I directly enter a cell level effective heat capacity?](https://pybamm.discourse.group/t/lumped-thermal-model-can-i-directly-enter-a-cell-level-effective-heat-capacity/234)

<div class="topic-metadata">

**Author:** [@ChaddKiggins](https://pybamm.discourse.group/u/ChaddKiggins)\
**Replies:** 1\
**Last updated:** [4 April 2025 00:32 UTC](https://pybamm.discourse.group/t/lumped-thermal-model-can-i-directly-enter-a-cell-level-effective-heat-capacity/234 "2025-04-04T00:32:59Z")

</div>

Hi all, I have a question regarding the lumped thermal model. Currently, it is formulated by defining the thickness and densities of the anode (film & current collector), separator, & cathode (film & current collector).…

---

## [Importing previous simulation output into a new simulation using an interpolant](https://pybamm.discourse.group/t/importing-previous-simulation-output-into-a-new-simulation-using-an-interpolant/236)

<div class="topic-metadata">

**Author:** [@isaac\_basil](https://pybamm.discourse.group/u/isaac_basil)\
**Replies:** 5\
**Last updated:** [31 March 2025 06:57 UTC](https://pybamm.discourse.group/t/importing-previous-simulation-output-into-a-new-simulation-using-an-interpolant/236 "2025-03-31T06:57:19Z")

</div>

Hi, I am trying to solve 2 simulations sequentially, and use an output from the first simulation as an input to the second. This output is a function of both space and time, j(x,t). I have 2 questions: I’m trying to …

---

## [Resolving Random Number Generation Conflict with CasADi's \_set\_random\_seed](https://pybamm.discourse.group/t/resolving-random-number-generation-conflict-with-casadis-set-random-seed/283)

<div class="topic-metadata">

**Author:** [@squirrel](https://pybamm.discourse.group/u/squirrel)\
**Replies:** 0\
**Last updated:** [29 March 2025 02:19 UTC](https://pybamm.discourse.group/t/resolving-random-number-generation-conflict-with-casadis-set-random-seed/283 "2025-03-29T02:19:28Z")

</div>

Hi, I encountered an issue when using the CasADi solver. While running the following code, I found that the random numbers were not being generated properly. I discovered that if the CasADi solver is used, the function \_…

---

## [Issues with Aging Simulation of LGM50 Cell: Current Behavior, Voltage Rise, and Feature Extraction](https://pybamm.discourse.group/t/issues-with-aging-simulation-of-lgm50-cell-current-behavior-voltage-rise-and-feature-extraction/276)

<div class="topic-metadata">

**Author:** [@davimoli](https://pybamm.discourse.group/u/davimoli)\
**Replies:** 0\
**Last updated:** [26 March 2025 11:05 UTC](https://pybamm.discourse.group/t/issues-with-aging-simulation-of-lgm50-cell-current-behavior-voltage-rise-and-feature-extraction/276 "2025-03-26T11:05:08Z")

</div>

Hi, I am simulating an aging experiment for an LGM50 cell using PyBaMM, involving constant current discharge and CCCV charging cycles. My goal is to analyze the degradation behavior over 500 cycles, including feature e…

---

## [Building Lithium Sulfur model using Pybamm](https://pybamm.discourse.group/t/building-lithium-sulfur-model-using-pybamm/265)

<div class="topic-metadata">

**Author:** [@hopitigala](https://pybamm.discourse.group/u/hopitigala)\
**Replies:** 0\
**Last updated:** [24 March 2025 14:53 UTC](https://pybamm.discourse.group/t/building-lithium-sulfur-model-using-pybamm/265 "2025-03-24T14:53:46Z")

</div>

Hi all, I am new to PyBaMM. In past few months, I have been trying to simulate Li-S battery model using the capabilities of PyBaMM. I found a zero-dimensional model developed by another group based on PyBaMM. It was dev…

---

## [Using existing control equations to solve solid-state battery problems](https://pybamm.discourse.group/t/using-existing-control-equations-to-solve-solid-state-battery-problems/233)

<div class="topic-metadata">

**Author:** [@Santiago\_peace](https://pybamm.discourse.group/u/Santiago_peace)\
**Replies:** 0\
**Last updated:** [14 March 2025 13:40 UTC](https://pybamm.discourse.group/t/using-existing-control-equations-to-solve-solid-state-battery-problems/233 "2025-03-14T13:40:25Z")

</div>

Dear developer, hello. The difference between solid-state batteries and currently commercialized batteries lies in the electrolyte. Is it feasible to use existing models to simulate solid-state batteries by setting certa…

---

## [How to update a matrix variable](https://pybamm.discourse.group/t/how-to-update-a-matrix-variable/229)

<div class="topic-metadata">

**Author:** [@ldy](https://pybamm.discourse.group/u/ldy)\
**Replies:** 0\
**Last updated:** [12 March 2025 02:42 UTC](https://pybamm.discourse.group/t/how-to-update-a-matrix-variable/229 "2025-03-12T02:42:20Z")

</div>

I was trying to implemnt a data driven thermal model in pybamm. It requires to evolve a hidden state which can be something like this: h\_t=(A \* h\_t-1 + B \* input) \* dt + h\_t-1, this hidden state is a matrix, I am just wo…

---

## [Particle phases default option](https://pybamm.discourse.group/t/particle-phases-default-option/218)

<div class="topic-metadata">

**Author:** [@fmaletic](https://pybamm.discourse.group/u/fmaletic)\
**Replies:** 1\
**Last updated:** [11 March 2025 00:29 UTC](https://pybamm.discourse.group/t/particle-phases-default-option/218 "2025-03-11T00:29:23Z")

</div>

Hi, I’ve noticed that there is a difference in simulation results when using "particle phases": ("1", "1") and with the default option, which, from what I understand from the source code, is just "particle phases": "…

[Previous page](https://pybamm.discourse.group/c/pybamm-qa/6.md)

[Next page](https://pybamm.discourse.group/c/pybamm-qa/6.md?page=2)
