Skip to content

Commit

Permalink
Merge pull request #2249 from DrSOKane/develop
Browse files Browse the repository at this point in the history
Added throughput variables for degradation sudies
  • Loading branch information
valentinsulzer committed Aug 19, 2022
2 parents db61076 + 7a1f46b commit a1bc678
Show file tree
Hide file tree
Showing 14 changed files with 153 additions and 16 deletions.
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# [Unreleased](https://github.com/pybamm-team/PyBaMM/)

## Features

- Added new cumulative variables `Throughput capacity [A.h]` and `Throughput energy [W.h]` to standard variables and summary variables, to assist with degradation studies. Throughput variables are only calculated if `calculate discharge energy` is set to `true`. `Time [s]` and `Time [h]` also added to summary variables. ([#2249](https://github.com/pybamm-team/PyBaMM/pull/2249))
- Added `lipf6_OKane2022` electrolyte to `OKane2022` parameter set ([#2249](https://github.com/pybamm-team/PyBaMM/pull/2249))

## Bug fixes

- Added new parameter `Ratio of lithium moles to SEI moles` (short name z_sei) to fix a bug where this number was incorrectly hardcoded to 1. ([#2222](https://github.com/pybamm-team/PyBaMM/pull/2222))
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# LiPF6 electrolyte parameters

Parameters for a LiPF6 electrolyte, from the paper

> Simon O'Kane, Weilong Ai, Ganesh Madabattula, Diego Alonso-Alvarez, Robert Timms, Valentin Sulzer, Jacqueline Edge, Billy Wu, Gregory Offer, and Monica Marinescu. ["Lithium-ion battery degradation: how to model it."](https://pubs.rsc.org/en/content/articlelanding/2022/cp/d2cp00417h) Physical Chemistry: Chemical Physics 24 (2022): 7909-7922
and references therein.
Empty file.
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
from pybamm import exp, constants


def electrolyte_conductivity_Nyman2008_arrhenius(c_e, T):
"""
Conductivity of LiPF6 in EC:EMC (3:7) as a function of ion concentration. The data
comes from [1], with Arrhenius temperature dependence added from [2].
References
----------
.. [1] A. Nyman, M. Behm, and G. Lindbergh, "Electrochemical characterisation and
modelling of the mass transport phenomena in LiPF6-EC-EMC electrolyte,"
Electrochim. Acta, vol. 53, no. 22, pp. 6356–6365, 2008.
.. [2] Ecker, Madeleine, et al. "Parameterization of a physico-chemical model of
a lithium-ion battery i. determination of parameters." Journal of the
Electrochemical Society 162.9 (2015): A1836-A1848.
Parameters
----------
c_e: :class:`pybamm.Symbol`
Dimensional electrolyte concentration
T: :class:`pybamm.Symbol`
Dimensional temperature
Returns
-------
:class:`pybamm.Symbol`
Solid diffusivity
"""

sigma_e = (
0.1297 * (c_e / 1000) ** 3 - 2.51 * (c_e / 1000) ** 1.5 + 3.329 * (c_e / 1000)
)

# Nyman et al. (2008) does not provide temperature dependence
# So use temperature dependence from Ecker et al. (2015) instead

E_sigma_e = 17000
arrhenius = exp(E_sigma_e / constants.R * (1 / 298.15 - 1 / T))

return sigma_e * arrhenius
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
from pybamm import exp, constants


def electrolyte_diffusivity_Nyman2008_arrhenius(c_e, T):
"""
Diffusivity of LiPF6 in EC:EMC (3:7) as a function of ion concentration. The data
comes from [1], with Arrhenius temperature dependence added from [2].
References
----------
.. [1] A. Nyman, M. Behm, and G. Lindbergh, "Electrochemical characterisation and
modelling of the mass transport phenomena in LiPF6-EC-EMC electrolyte,"
Electrochim. Acta, vol. 53, no. 22, pp. 6356–6365, 2008.
.. [2] Ecker, Madeleine, et al. "Parameterization of a physico-chemical model of
a lithium-ion battery i. determination of parameters." Journal of the
Electrochemical Society 162.9 (2015): A1836-A1848.
Parameters
----------
c_e: :class:`pybamm.Symbol`
Dimensional electrolyte concentration
T: :class:`pybamm.Symbol`
Dimensional temperature
Returns
-------
:class:`pybamm.Symbol`
Solid diffusivity
"""

D_c_e = 8.794e-11 * (c_e / 1000) ** 2 - 3.972e-10 * (c_e / 1000) + 4.862e-10

# Nyman et al. (2008) does not provide temperature dependence
# So use temperature dependence from Ecker et al. (2015) instead

E_D_c_e = 17000
arrhenius = exp(E_D_c_e / constants.R * (1 / 298.15 - 1 / T))

return D_c_e * arrhenius
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
Name [units],Value,Reference,Notes
# Empty rows and rows starting with ‘#’ will be ignored,,,
,,,
# Electrolyte properties,,,
Typical electrolyte concentration [mol.m-3],1000,Chen 2020,
Initial concentration in electrolyte [mol.m-3],1000,Chen 2020,
Cation transference number,0.2594,Chen 2020,
1 + dlnf/dlnc,1,,
Electrolyte diffusivity [m2.s-1],[function]electrolyte_diffusivity_Nyman2008_arrhenius,OKane 2022,
Electrolyte conductivity [S.m-1],[function]electrolyte_conductivity_Nyman2008_arrhenius,OKane 2022,
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

Some example parameters for lithium plating from the paper:

> O’Kane, S. E. J., Ai, W., Madabattula, G., Alonso-Alvarez, D., Timms, R, Sulzer, V., Edge, J. S., Wu, B., Offer, G. J., & Marinescu, M. (2022) Lithium-ion battery degradation: how to model it. Physical Chemistry: Chemical Physics, accepted.
> Simon O'Kane, Weilong Ai, Ganesh Madabattula, Diego Alonso-Alvarez, Robert Timms, Valentin Sulzer, Jacqueline Edge, Billy Wu, Gregory Offer, and Monica Marinescu. ["Lithium-ion battery degradation: how to model it."](https://pubs.rsc.org/en/content/articlelanding/2022/cp/d2cp00417h) Physical Chemistry: Chemical Physics 24 (2022): 7909-7922
and references therein.

Note: this parameter set does not claim to be representative of the true parameter values. These are merely the parameter values that were used in the referenced papers.
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# LG M50 Graphite anode parameters

Parameters for a LG M50 graphite anode, from the paper
Parameters for an LG M50 graphite negative electrode, from the paper

> Simon O'Kane, Weilong Ai, Ganesh Madabattula, Diego Alonso-Alvarez, Robert Timms, Valentin Sulzer, Jacqueline Edge, Billy Wu, Gregory Offer, and Monica Marinescu. ["Lithium-ion battery degradation: how to model it."](https://pubs.rsc.org/en/content/articlelanding/2022/cp/d2cp00417h) Physical Chemistry: Chemical Physics 24 (2022): 7909-7922
Expand Down
13 changes: 5 additions & 8 deletions pybamm/input/parameters/lithium_ion/seis/OKane2022/README.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,9 @@
# SEI parameters

Some example parameters for SEI growth from the papers:
Parameters for SEI growth from the paper

> Ramadass, P., Haran, B., Gomadam, P. M., White, R., & Popov, B. N. (2004). Development of first principles capacity fade model for Li-ion cells. Journal of the Electrochemical Society, 151(2), A196-A203.
> Ploehn, H. J., Ramadass, P., & White, R. E. (2004). Solvent diffusion model for aging of lithium-ion battery cells. Journal of The Electrochemical Society, 151(3), A456-A462.
> Single, F., Latz, A., & Horstmann, B. (2018). Identifying the mechanism of continued growth of the solid–electrolyte interphase. ChemSusChem, 11(12), 1950-1955.
> Safari, M., Morcrette, M., Teyssot, A., & Delacour, C. (2009). Multimodal Physics-Based Aging Model for Life Prediction of Li-Ion Batteries. Journal of The Electrochemical Society, 156(3),
> Yang, X., Leng, Y., Zhang, G., Ge, S., Wang, C. (2017). Modeling of lithium plating induced aging of lithium-ion batteries: Transition from linear to nonlinear aging. Journal of Power Sources, 360, 28-40.
> Waldmann, T., Wilka, M., Kasper, M., Fleischammer M., Wohlfahrt-Mehrens M. (2014). Temperature dependent ageing mechanisms in Lithium-ion batteris: A Post-Mortem study. Journal of Power Sources, 262, 129-135.
> Simon O'Kane, Weilong Ai, Ganesh Madabattula, Diego Alonso-Alvarez, Robert Timms, Valentin Sulzer, Jacqueline Edge, Billy Wu, Gregory Offer, and Monica Marinescu. ["Lithium-ion battery degradation: how to model it."](https://pubs.rsc.org/en/content/articlelanding/2022/cp/d2cp00417h) Physical Chemistry: Chemical Physics 24 (2022): 7909-7922
Note: this parameter set does not claim to be representative of the true parameter values. Instead these are parameter values that were used to fit SEI models to observed experimental data in the referenced papers.
and references therein.

Note: this parameter set does not claim to be representative of the true parameter values. These are merely the parameter values that were used in the referenced papers.
5 changes: 3 additions & 2 deletions pybamm/models/full_battery_models/base_battery_model.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,9 @@ class BatteryModelOptions(pybamm.FuzzyDict):
option for the negative and positive electrodes.
* "calculate discharge energy": str
Whether to calculate the discharge energy. Must be one of "true" or
"false". "false" is the default, since calculating the discharge
Whether to calculate the discharge energy, throughput energy and
throughput capacity in addition to discharge capacity. Must be one of
"true" or "false". "false" is the default, since calculating discharge
energy can be computationally expensive for simple models like SPM.
* "cell geometry" : str
Sets the geometry of the cell. Can be "pouch" (default) or
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -185,6 +185,10 @@ def set_summary_variables(self):
Sets the default summary variables.
"""
summary_variables = [
"Time [s]",
"Time [h]",
"Throughput capacity [A.h]",
"Throughput energy [W.h]",
"Positive electrode capacity [A.h]",
# LAM, LLI
"Loss of active material in positive electrode [%]",
Expand Down
4 changes: 4 additions & 0 deletions pybamm/models/standard_variables.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,10 @@ def __init__(self):
self.Q_Ah = pybamm.Variable("Discharge capacity [A.h]")
self.Q_Wh = pybamm.Variable("Discharge energy [W.h]")

# Throughput capacity and energy (cumulative)
self.Qt_Ah = pybamm.Variable("Throughput capacity [A.h]")
self.Qt_Wh = pybamm.Variable("Throughput energy [W.h]")

# Electrolyte concentration
self.c_e_n = pybamm.Variable(
"Negative electrolyte concentration",
Expand Down
33 changes: 30 additions & 3 deletions pybamm/models/submodels/external_circuit/base_external_circuit.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,29 +12,50 @@ def __init__(self, param, options):

def get_fundamental_variables(self):
Q_Ah = pybamm.standard_variables.Q_Ah

variables = {"Discharge capacity [A.h]": Q_Ah}
if self.options["calculate discharge energy"] == "true":
Q_Wh = pybamm.standard_variables.Q_Wh
variables.update({"Discharge energy [W.h]": Q_Wh})
Qt_Wh = pybamm.standard_variables.Qt_Wh
Qt_Ah = pybamm.standard_variables.Qt_Ah
variables.update({
"Discharge energy [W.h]": Q_Wh,
"Throughput energy [W.h]": Qt_Wh,
"Throughput capacity [A.h]": Qt_Ah,
})
else:
variables.update({
"Discharge energy [W.h]": pybamm.Scalar(0),
"Throughput energy [W.h]": pybamm.Scalar(0),
"Throughput capacity [A.h]": pybamm.Scalar(0),
})
return variables

def set_initial_conditions(self, variables):
Q_Ah = variables["Discharge capacity [A.h]"]
self.initial_conditions[Q_Ah] = pybamm.Scalar(0)
if self.options["calculate discharge energy"] == "true":
Q_Wh = variables["Discharge energy [W.h]"]
Qt_Wh = variables["Throughput energy [W.h]"]
Qt_Ah = variables["Throughput capacity [A.h]"]
self.initial_conditions[Q_Wh] = pybamm.Scalar(0)
self.initial_conditions[Qt_Wh] = pybamm.Scalar(0)
self.initial_conditions[Qt_Ah] = pybamm.Scalar(0)

def set_rhs(self, variables):
# ODE for discharge capacity
# ODEs for discharge capacity and throughput capacity
Q_Ah = variables["Discharge capacity [A.h]"]
I = variables["Current [A]"]

self.rhs[Q_Ah] = I * self.param.timescale / 3600
if self.options["calculate discharge energy"] == "true":
Q_Wh = variables["Discharge energy [W.h]"]
Qt_Wh = variables["Throughput energy [W.h]"]
Qt_Ah = variables["Throughput capacity [A.h]"]
V = variables["Terminal voltage [V]"]
self.rhs[Q_Wh] = I * V * self.param.timescale / 3600
self.rhs[Qt_Wh] = abs(I * V) * self.param.timescale / 3600
self.rhs[Qt_Ah] = abs(I) * self.param.timescale / 3600


class LeadingOrderBaseModel(BaseModel):
Expand All @@ -48,5 +69,11 @@ def get_fundamental_variables(self):
variables = {"Discharge capacity [A.h]": Q_Ah}
if self.options["calculate discharge energy"] == "true":
Q_Wh = pybamm.Variable("Leading-order discharge energy [W.h]")
variables.update({"Discharge energy [W.h]": Q_Wh})
Qt_Wh = pybamm.Variable("Leading-order throughput energy [W.h]")
Qt_Ah = pybamm.Variable("Leading-order throughput capacity [A.h]")
variables.update({
"Discharge energy [W.h]": Q_Wh,
"Throughput energy [W.h]": Qt_Wh,
"Throughput capacity [A.h]": Qt_Ah,
})
return variables
2 changes: 1 addition & 1 deletion pybamm/parameters/parameter_sets.py
Original file line number Diff line number Diff line change
Expand Up @@ -239,7 +239,7 @@
"negative electrode": "graphite_OKane2022",
"separator": "separator_Chen2020",
"positive electrode": "nmc_OKane2022",
"electrolyte": "lipf6_Nyman2008",
"electrolyte": "lipf6_OKane2022",
"experiment": "1C_discharge_from_full_Chen2020",
"sei": "OKane2022",
"lithium plating": "okane2022_Li_plating",
Expand Down

0 comments on commit a1bc678

Please sign in to comment.