Skip to content

[Bug]: Voltage contributions in SPMe/DFN half-cell model #5124

@NicolaCourtier

Description

@NicolaCourtier

PyBaMM Version

25.6

Python Version

3.12.3

Describe the bug

It looks like there is a missing or inaccurate term in the voltage contributions plot of the SPMe and DFN models when using the {"working electrode": "positive"} option.

Steps to Reproduce

import pybamm

for model, param_set, experiment in zip(
    [pybamm.lithium_ion.SPMe, pybamm.lithium_ion.DFN],
    ["OKane2022_graphite_SiOx_halfcell", "Xu2019"],
    [
        ["Charge at 2C until 1.5V", "Hold at 1.5V for 20 minutes"],
        ["Discharge at 2C until 3.0V", "Hold at 3.0V for 20 minutes"],
    ]
):
    sim = pybamm.Simulation(
        model=model({"working electrode": "positive"}),
        parameter_values=pybamm.ParameterValues(param_set),
        experiment=experiment,
    )
    sol = sim.solve()
    sol.plot_voltage_components()
Image Image

Relevant log output

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions