From 28e2382bc3311acadd08a069ede5b3d933e3d0a0 Mon Sep 17 00:00:00 2001 From: tinosulzer Date: Tue, 28 Mar 2023 10:11:55 +0000 Subject: [PATCH 1/3] Update version to v23.3 --- CHANGELOG.md | 2 + CITATION.cff | 2 +- docs/conf.py | 2 +- docs/source/_static/versions.json | 121 +----------------------------- pybamm/version.py | 2 +- vcpkg.json | 2 +- 6 files changed, 7 insertions(+), 124 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 5b7e7240c4..3ab880ebe8 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,7 @@ # [Unreleased](https://github.com/pybamm-team/PyBaMM/) +# [v23.3](https://github.com/pybamm-team/PyBaMM/tree/v23.3) - 2023-03-31 + ## Features - Added new variables, related to electrode balance, for the `ElectrodeSOH` model ([#2807](https://github.com/pybamm-team/PyBaMM/pull/2807)) diff --git a/CITATION.cff b/CITATION.cff index 4b3a76088c..ae1b7c73ba 100644 --- a/CITATION.cff +++ b/CITATION.cff @@ -24,6 +24,6 @@ keywords: - "expression tree" - "python" - "symbolic differentiation" -version: "23.2" +version: "23.3" repository-code: "https://github.com/pybamm-team/PyBaMM" title: "Python Battery Mathematical Modelling (PyBaMM)" diff --git a/docs/conf.py b/docs/conf.py index 4b79e4bc4e..0707ffbcaf 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -26,7 +26,7 @@ author = "The PyBaMM Team" # The short X.Y version -version = "23.2" +version = "23.3" # The full version, including alpha/beta/rc tags release = version diff --git a/docs/source/_static/versions.json b/docs/source/_static/versions.json index 0225a5d5d0..8c4282ee6c 100644 --- a/docs/source/_static/versions.json +++ b/docs/source/_static/versions.json @@ -1,120 +1 @@ -[ - { - "name": "latest", - "version": "latest", - "url": "https://pybamm.readthedocs.io/en/latest/" - }, - { - "name": "stable", - "version": "stable", - "url": "https://pybamm.readthedocs.io/en/stable/" - }, - { - "version": "v23.2", - "url": "https://pybamm.readthedocs.io/en/v23.2/" - }, - { - "version": "v23.1", - "url": "https://pybamm.readthedocs.io/en/v23.1/" - }, - { - "version": "v22.12", - "url": "https://pybamm.readthedocs.io/en/v22.12/" - }, - { - "version": "v22.11.1", - "url": "https://pybamm.readthedocs.io/en/v22.11.1/" - }, - { - "version": "v22.11", - "url": "https://pybamm.readthedocs.io/en/v22.11/" - }, - { - "version": "v22.10", - "url": "https://pybamm.readthedocs.io/en/v22.10/" - }, - { - "version": "v22.9", - "url": "https://pybamm.readthedocs.io/en/v22.9/" - }, - { - "version": "v22.8", - "url": "https://pybamm.readthedocs.io/en/v22.8/" - }, - { - "version": "v22.7", - "url": "https://pybamm.readthedocs.io/en/v22.7/" - }, - { - "version": "v22.6", - "url": "https://pybamm.readthedocs.io/en/v22.6/" - }, - { - "version": "v22.5", - "url": "https://pybamm.readthedocs.io/en/v22.5/" - }, - { - "version": "v22.4", - "url": "https://pybamm.readthedocs.io/en/v22.4/" - }, - { - "version": "v22.3", - "url": "https://pybamm.readthedocs.io/en/v22.3/" - }, - { - "version": "v22.2", - "url": "https://pybamm.readthedocs.io/en/v22.3/" - }, - { - "version": "v22.1", - "url": "https://pybamm.readthedocs.io/en/v22.1/" - }, - { - "version": "v21.12", - "url": "https://pybamm.readthedocs.io/en/v21.12/" - }, - { - "version": "v21.11", - "url": "https://pybamm.readthedocs.io/en/v21.11/" - }, - { - "version": "v21.10", - "url": "https://pybamm.readthedocs.io/en/v21.10/" - }, - { - "version": "v21.9", - "url": "https://pybamm.readthedocs.io/en/v21.9/" - }, - { - "version": "v21.08", - "url": "https://pybamm.readthedocs.io/en/v21.08/" - }, - { - "version": "v0.4.0", - "url": "https://pybamm.readthedocs.io/en/v0.4.0/" - }, - { - "version": "v0.3.0", - "url": "https://pybamm.readthedocs.io/en/v0.3.0/" - }, - { - "version": "v0.2.3", - "url": "https://pybamm.readthedocs.io/en/v0.2.3/" - }, - { - "version": "v0.2.2", - "url": "https://pybamm.readthedocs.io/en/v0.2.2/" - }, - { - "version": "v0.2.1", - "url": "https://pybamm.readthedocs.io/en/v0.2.1/" - }, - { - "version": "v0.2.0", - "url": "https://pybamm.readthedocs.io/en/v0.2.0/" - }, - { - "version": "v0.1.0", - "url": "https://pybamm.readthedocs.io/en/v0.1.0/" - } -] \ No newline at end of file +[{"name": "latest", "version": "latest", "url": "https://pybamm.readthedocs.io/en/latest/"}, {"name": "stable", "version": "stable", "url": "https://pybamm.readthedocs.io/en/stable/"}, {"version": "v23.3", "url": "https://pybamm.readthedocs.io/en/v23.3/"}, {"version": "v23.2", "url": "https://pybamm.readthedocs.io/en/v23.2/"}, {"version": "v23.1", "url": "https://pybamm.readthedocs.io/en/v23.1/"}, {"version": "v22.12", "url": "https://pybamm.readthedocs.io/en/v22.12/"}, {"version": "v22.11.1", "url": "https://pybamm.readthedocs.io/en/v22.11.1/"}, {"version": "v22.11", "url": "https://pybamm.readthedocs.io/en/v22.11/"}, {"version": "v22.10", "url": "https://pybamm.readthedocs.io/en/v22.10/"}, {"version": "v22.9", "url": "https://pybamm.readthedocs.io/en/v22.9/"}, {"version": "v22.8", "url": "https://pybamm.readthedocs.io/en/v22.8/"}, {"version": "v22.7", "url": "https://pybamm.readthedocs.io/en/v22.7/"}, {"version": "v22.6", "url": "https://pybamm.readthedocs.io/en/v22.6/"}, {"version": "v22.5", "url": "https://pybamm.readthedocs.io/en/v22.5/"}, {"version": "v22.4", "url": "https://pybamm.readthedocs.io/en/v22.4/"}, {"version": "v22.3", "url": "https://pybamm.readthedocs.io/en/v22.3/"}, {"version": "v22.2", "url": "https://pybamm.readthedocs.io/en/v22.3/"}, {"version": "v22.1", "url": "https://pybamm.readthedocs.io/en/v22.1/"}, {"version": "v21.12", "url": "https://pybamm.readthedocs.io/en/v21.12/"}, {"version": "v21.11", "url": "https://pybamm.readthedocs.io/en/v21.11/"}, {"version": "v21.10", "url": "https://pybamm.readthedocs.io/en/v21.10/"}, {"version": "v21.9", "url": "https://pybamm.readthedocs.io/en/v21.9/"}, {"version": "v21.08", "url": "https://pybamm.readthedocs.io/en/v21.08/"}, {"version": "v0.4.0", "url": "https://pybamm.readthedocs.io/en/v0.4.0/"}, {"version": "v0.3.0", "url": "https://pybamm.readthedocs.io/en/v0.3.0/"}, {"version": "v0.2.3", "url": "https://pybamm.readthedocs.io/en/v0.2.3/"}, {"version": "v0.2.2", "url": "https://pybamm.readthedocs.io/en/v0.2.2/"}, {"version": "v0.2.1", "url": "https://pybamm.readthedocs.io/en/v0.2.1/"}, {"version": "v0.2.0", "url": "https://pybamm.readthedocs.io/en/v0.2.0/"}, {"version": "v0.1.0", "url": "https://pybamm.readthedocs.io/en/v0.1.0/"}] \ No newline at end of file diff --git a/pybamm/version.py b/pybamm/version.py index 029e0b2224..72e2b6cfd3 100644 --- a/pybamm/version.py +++ b/pybamm/version.py @@ -1 +1 @@ -__version__ = "23.2" +__version__ = "23.3" diff --git a/vcpkg.json b/vcpkg.json index 8e393e9ad0..8e44af9537 100644 --- a/vcpkg.json +++ b/vcpkg.json @@ -1,6 +1,6 @@ { "name": "pybamm", - "version-string": "23.2", + "version-string": "23.3", "dependencies": [ "casadi", { From 8a51a42aa480ab3a435103e289f271a4506a8718 Mon Sep 17 00:00:00 2001 From: Valentin Sulzer Date: Fri, 31 Mar 2023 11:02:25 -0400 Subject: [PATCH 2/3] rename Open-circuit voltage to Bulk open-circuit voltage --- .../models/full_battery_models/base_battery_model.py | 2 +- pybamm/util.py | 10 +++++----- .../test_models/standard_output_comparison.py | 2 +- tests/integration/test_models/standard_output_tests.py | 2 +- 4 files changed, 8 insertions(+), 8 deletions(-) diff --git a/pybamm/models/full_battery_models/base_battery_model.py b/pybamm/models/full_battery_models/base_battery_model.py index e82f3d5868..4ea4611133 100644 --- a/pybamm/models/full_battery_models/base_battery_model.py +++ b/pybamm/models/full_battery_models/base_battery_model.py @@ -1149,7 +1149,7 @@ def set_voltage_variables(self): self.variables.update( { "Surface open-circuit voltage [V]": ocv_surf, - "Open-circuit voltage [V]": ocv_bulk, + "Bulk open-circuit voltage [V]": ocv_bulk, "Particle concentration overpotential [V]": eta_particle, "X-averaged reaction overpotential [V]": eta_r_av, "X-averaged SEI film overpotential [V]": eta_sei_av, diff --git a/pybamm/util.py b/pybamm/util.py index 5f74470b17..c976e645d8 100644 --- a/pybamm/util.py +++ b/pybamm/util.py @@ -66,12 +66,12 @@ def __getitem__(self, key): ) if "Measured open circuit voltage" in key: raise KeyError( - "The variable for open circuit voltage is now called " - "'Open-circuit voltage [V]'. The variable that used to be called " + "The variable that used to be called " "'Measured open circuit voltage [V]' is now called " - "'Surface open-circuit voltage [V]', but this is not the true " - "open-circuit voltage of the cell since it includes the " - "particle concentration overpotentials." + "'Surface open-circuit voltage [V]'. There is also another " + "variable called 'Bulk open-circuit voltage [V]' which is the" + "open-circuit voltage evaluated at the average particle " + "concentrations." ) best_matches = self.get_best_matches(key) for k in best_matches: diff --git a/tests/integration/test_models/standard_output_comparison.py b/tests/integration/test_models/standard_output_comparison.py index 0431a9b481..fcc1390551 100644 --- a/tests/integration/test_models/standard_output_comparison.py +++ b/tests/integration/test_models/standard_output_comparison.py @@ -92,7 +92,7 @@ def __init__(self, time, solutions): def test_all(self): # Potentials - self.compare("Open-circuit voltage [V]") + self.compare("Bulk open-circuit voltage [V]") # Currents self.compare( "X-averaged negative electrode volumetric " diff --git a/tests/integration/test_models/standard_output_tests.py b/tests/integration/test_models/standard_output_tests.py index 3d70eefdab..a119f84404 100644 --- a/tests/integration/test_models/standard_output_tests.py +++ b/tests/integration/test_models/standard_output_tests.py @@ -145,7 +145,7 @@ def __init__(self, model, param, disc, solution, operating_condition): self.ocp_p = solution[ f"Positive electrode {self.phase_name_p}bulk open-circuit potential [V]" ] - self.ocv = solution["Open-circuit voltage [V]"] + self.ocv = solution["Bulk open-circuit voltage [V]"] self.voltage = solution["Voltage [V]"] def test_each_reaction_overpotential(self): From bf594c6c45de07f6df3e2f44f27659d757daafde Mon Sep 17 00:00:00 2001 From: Valentin Sulzer Date: Fri, 31 Mar 2023 11:08:51 -0400 Subject: [PATCH 3/3] changelog --- CHANGELOG.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 0cf95eaca2..482f9cd86e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -9,7 +9,7 @@ - Added method to calculate maximum theoretical energy. ([#2777](https://github.com/pybamm-team/PyBaMM/pull/2777)) and add to summary variables ([#2781](https://github.com/pybamm-team/PyBaMM/pull/2781)) - Renamed "Terminal voltage [V]" to just "Voltage [V]". "Terminal voltage [V]" can still be used and will return the same value as "Voltage [V]". ([#2740](https://github.com/pybamm-team/PyBaMM/pull/2740)) - Added "Negative electrode surface potential difference at separator interface [V]", which is the value of the surface potential difference (`phi_s - phi_e`) at the anode/separator interface, commonly controlled in fast-charging algorithms to avoid plating. Also added "Positive electrode surface potential difference at separator interface [V]". ([#2740](https://github.com/pybamm-team/PyBaMM/pull/2740)) -- Added "Open-circuit voltage [V]", which is the open-circuit voltage as calculated from the bulk particle concentrations. The old variable "Measured open circuit voltage [V]", which referred to the open-circuit potential as calculated from the surface particle concentrations, has been renamed to "Surface open-circuit voltage [V]". ([#2740](https://github.com/pybamm-team/PyBaMM/pull/2740)) +- Added "Bulk open-circuit voltage [V]", which is the open-circuit voltage as calculated from the bulk particle concentrations. The old variable "Measured open circuit voltage [V]", which referred to the open-circuit potential as calculated from the surface particle concentrations, has been renamed to "Surface open-circuit voltage [V]". ([#2740](https://github.com/pybamm-team/PyBaMM/pull/2740)) "Bulk open-circuit voltage [V]" was briefly named "Open-circuit voltage [V]", but this was changed in ([#2845](https://github.com/pybamm-team/PyBaMM/pull/2845)) - Added an example for `plot_voltage_components`, explaining what the different voltage components are. ([#2740](https://github.com/pybamm-team/PyBaMM/pull/2740)) ## Bug fixes @@ -30,7 +30,7 @@ - `ElectrodeSOH.solve` now returns a `{str: float}` dict instead of a `pybamm.Solution` object (to avoid having to do `.data[0]` every time). In any code that uses `sol = ElectrodeSOH.solve()`, `sol[key].data[0]` should be replaced with `sol[key]`. ([#2779](https://github.com/pybamm-team/PyBaMM/pull/2779)) - Removed "... cation signed stoichiometry" and "... electrons in reaction" parameters, they are now hardcoded. ([#2778](https://github.com/pybamm-team/PyBaMM/pull/2778)) - When using `solver.step()`, the first time point in the step is shifted by `pybamm.settings.step_start_offset` (default 1 ns) to avoid having duplicate times in the solution steps from the end of one step and the start of the next. ([#2773](https://github.com/pybamm-team/PyBaMM/pull/2773)) -- Renamed "Measured open circuit voltage [V]" to "Surface open-circuit voltage [V]". This variable was calculated from surface particle concentrations, and hence "hid" the overpotential from particle gradients. The new variable "Open-circuit voltage [V]" is calculated from bulk particle concentrations instead. ([#2740](https://github.com/pybamm-team/PyBaMM/pull/2740)) +- Renamed "Measured open circuit voltage [V]" to "Surface open-circuit voltage [V]". This variable was calculated from surface particle concentrations, and hence "hid" the overpotential from particle gradients. The new variable "Bulk open-circuit voltage [V]" is calculated from bulk particle concentrations instead. ([#2740](https://github.com/pybamm-team/PyBaMM/pull/2740)) - Renamed all references to "open circuit" to be "open-circuit" instead. ([#2740](https://github.com/pybamm-team/PyBaMM/pull/2740)) - Renamed parameter "1 + dlnf/dlnc" to "Thermodynamic factor". ([#2727](https://github.com/pybamm-team/PyBaMM/pull/2727)) - All PyBaMM models are now dimensional. This has been benchmarked against dimensionless models and found to give around the same solve time. Implementing dimensional models greatly reduces the barrier to entry for adding new models. However, this comes with several breaking changes: (i) the `timescale` and `length_scales` attributes of a model have been removed (they are no longer needed) (ii) several dimensionless variables are no longer defined, but the corresponding dimensional variables can still be accessed by adding the units to the name (iii) some parameters used only for non-dimensionalization, such as "Typical current [A]", have been removed ([#2419](https://github.com/pybamm-team/PyBaMM/pull/2419))