diff --git a/CHANGELOG.md b/CHANGELOG.md index 2acfddfb34..aeb08bf4a4 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,7 @@ - Added parameter set for an A123 LFP cell ([#1209](https://github.com/pybamm-team/PyBaMM/pull/1209)) - Added variables related to equivalent circuit models ([#1204](https://github.com/pybamm-team/PyBaMM/pull/1204)) +- Added the `Integrated` electrolyte conductivity submodel ([#1188](https://github.com/pybamm-team/PyBaMM/pull/1188)) - Added an example script to check conservation of lithium ([#1186](https://github.com/pybamm-team/PyBaMM/pull/1186)) - Added `erf` and `erfc` functions ([#1184](https://github.com/pybamm-team/PyBaMM/pull/1184)) diff --git a/docs/source/models/submodels/electrolyte_conductivity/index.rst b/docs/source/models/submodels/electrolyte_conductivity/index.rst index 8d0be2223a..a723c32aab 100644 --- a/docs/source/models/submodels/electrolyte_conductivity/index.rst +++ b/docs/source/models/submodels/electrolyte_conductivity/index.rst @@ -7,5 +7,6 @@ Electrolyte Conductivity base_electrolyte_conductivity leading_order_conductivity composite_conductivity + integrated_conductivity full_conductivity surface_form/index diff --git a/docs/source/models/submodels/electrolyte_conductivity/integrated_conductivity.rst b/docs/source/models/submodels/electrolyte_conductivity/integrated_conductivity.rst new file mode 100644 index 0000000000..469e3e7dcb --- /dev/null +++ b/docs/source/models/submodels/electrolyte_conductivity/integrated_conductivity.rst @@ -0,0 +1,5 @@ +Integrated Model +================ + +.. autoclass:: pybamm.electrolyte_conductivity.Integrated + :members: diff --git a/pybamm/CITATIONS.txt b/pybamm/CITATIONS.txt index afff80c0a3..e71a23f27d 100644 --- a/pybamm/CITATIONS.txt +++ b/pybamm/CITATIONS.txt @@ -208,6 +208,16 @@ primaryClass={physics.app-ph}, publisher={IOP Publishing} } +@article{brosaplanella2020TSPMe, +title={Systematic derivation and validation of a reduced thermal-electrochemical model for lithium-ion batteries using asymptotic methods} +journal={Submitted for publication}, +author={Brosa Planella, Ferran and Sheikh, Muhammad and Widanage, Dhammika W}, +year={2020}, +eprint={2011.01611}, +archivePrefix={arXiv}, +primaryClass={physics.chem-ph}, +} + @article{lain2019design, title={Design Strategies for High Power vs. High Energy Lithium Ion Cells}, author={Lain, Michael J and Brandon, James and Kendrick, Emma}, diff --git a/pybamm/input/parameters/lithium-ion/electrolytes/lipf6_Nyman2008/electrolyte_conductivity_Nyman2008.py b/pybamm/input/parameters/lithium-ion/electrolytes/lipf6_Nyman2008/electrolyte_conductivity_Nyman2008.py index defa74e43b..f8885591f4 100644 --- a/pybamm/input/parameters/lithium-ion/electrolytes/lipf6_Nyman2008/electrolyte_conductivity_Nyman2008.py +++ b/pybamm/input/parameters/lithium-ion/electrolytes/lipf6_Nyman2008/electrolyte_conductivity_Nyman2008.py @@ -1,6 +1,3 @@ -from pybamm import exp, constants - - def electrolyte_conductivity_Nyman2008(c_e, T): """ Conductivity of LiPF6 in EC:EMC (3:7) as a function of ion concentration. The data @@ -27,7 +24,6 @@ def electrolyte_conductivity_Nyman2008(c_e, T): 0.1297 * (c_e / 1000) ** 3 - 2.51 * (c_e / 1000) ** 1.5 + 3.329 * (c_e / 1000) ) - E_k_e = 34700 - arrhenius = exp(E_k_e / constants.R * (1 / 298.15 - 1 / T)) + # Nyman et al. (2008) does not provide temperature dependence - return sigma_e * arrhenius + return sigma_e diff --git a/pybamm/input/parameters/lithium-ion/electrolytes/lipf6_Nyman2008/electrolyte_diffusivity_Nyman2008.py b/pybamm/input/parameters/lithium-ion/electrolytes/lipf6_Nyman2008/electrolyte_diffusivity_Nyman2008.py index bee3152dcf..2a832539d6 100644 --- a/pybamm/input/parameters/lithium-ion/electrolytes/lipf6_Nyman2008/electrolyte_diffusivity_Nyman2008.py +++ b/pybamm/input/parameters/lithium-ion/electrolytes/lipf6_Nyman2008/electrolyte_diffusivity_Nyman2008.py @@ -1,6 +1,3 @@ -from pybamm import exp, constants - - def electrolyte_diffusivity_Nyman2008(c_e, T): """ Diffusivity of LiPF6 in EC:EMC (3:7) as a function of ion concentration. The data @@ -24,7 +21,7 @@ def electrolyte_diffusivity_Nyman2008(c_e, T): """ D_c_e = 8.794e-11 * (c_e / 1000) ** 2 - 3.972e-10 * (c_e / 1000) + 4.862e-10 - E_D_e = 37040 - arrhenius = exp(E_D_e / constants.R * (1 / 298.15 - 1 / T)) - return D_c_e * arrhenius + # Nyman et al. (2008) does not provide temperature dependence + + return D_c_e diff --git a/pybamm/models/full_battery_models/base_battery_model.py b/pybamm/models/full_battery_models/base_battery_model.py index e5e5d6c9e2..74b1d10b6c 100644 --- a/pybamm/models/full_battery_models/base_battery_model.py +++ b/pybamm/models/full_battery_models/base_battery_model.py @@ -198,6 +198,7 @@ def options(self, extra_options): "current collector": "uniform", "particle": "Fickian diffusion", "particle shape": "spherical", + "electrolyte conductivity": "default", "thermal": "isothermal", "cell geometry": None, "external submodels": [], @@ -375,6 +376,19 @@ def options(self, extra_options): "placed at the top of the cell." ) + if options["electrolyte conductivity"] not in [ + "default", + "full", + "leading order", + "composite", + "integrated", + ]: + raise pybamm.OptionError( + "electrolyte conductivity model '{}' not recognised".format( + options["electrolyte conductivity"] + ) + ) + self._options = options def set_standard_output_variables(self): diff --git a/pybamm/models/full_battery_models/lithium_ion/dfn.py b/pybamm/models/full_battery_models/lithium_ion/dfn.py index ea8b7c31c1..f7e6f038ba 100644 --- a/pybamm/models/full_battery_models/lithium_ion/dfn.py +++ b/pybamm/models/full_battery_models/lithium_ion/dfn.py @@ -121,6 +121,13 @@ def set_electrolyte_submodel(self): self.param ) + if self.options["electrolyte conductivity"] not in ["default", "full"]: + raise pybamm.OptionError( + "electrolyte conductivity '{}' not suitable for DFN".format( + self.options["electrolyte conductivity"] + ) + ) + if self.options["surface form"] is False: self.submodels[ "electrolyte conductivity" diff --git a/pybamm/models/full_battery_models/lithium_ion/spm.py b/pybamm/models/full_battery_models/lithium_ion/spm.py index 313a3d930a..0adba3ff29 100644 --- a/pybamm/models/full_battery_models/lithium_ion/spm.py +++ b/pybamm/models/full_battery_models/lithium_ion/spm.py @@ -136,6 +136,13 @@ def set_electrolyte_submodel(self): surf_form = pybamm.electrolyte_conductivity.surface_potential_form + if self.options["electrolyte conductivity"] not in ["default", "leading order"]: + raise pybamm.OptionError( + "electrolyte conductivity '{}' not suitable for SPM".format( + self.options["electrolyte conductivity"] + ) + ) + if self.options["surface form"] is False: self.submodels[ "leading-order electrolyte conductivity" @@ -152,6 +159,7 @@ def set_electrolyte_submodel(self): self.submodels[ "leading-order " + domain.lower() + " electrolyte conductivity" ] = surf_form.LeadingOrderAlgebraic(self.param, domain) + self.submodels[ "electrolyte diffusion" ] = pybamm.electrolyte_diffusion.ConstantConcentration(self.param) diff --git a/pybamm/models/full_battery_models/lithium_ion/spme.py b/pybamm/models/full_battery_models/lithium_ion/spme.py index d057e2766a..fd7a61beea 100644 --- a/pybamm/models/full_battery_models/lithium_ion/spme.py +++ b/pybamm/models/full_battery_models/lithium_ion/spme.py @@ -136,9 +136,39 @@ def set_positive_electrode_submodel(self): def set_electrolyte_submodel(self): - self.submodels[ - "electrolyte conductivity" - ] = pybamm.electrolyte_conductivity.Composite(self.param) + if self.options["electrolyte conductivity"] not in [ + "default", + "composite", + "integrated", + ]: + raise pybamm.OptionError( + "electrolyte conductivity '{}' not suitable for SPMe".format( + self.options["electrolyte conductivity"] + ) + ) + + if self.options["surface form"] is False: + if self.options["electrolyte conductivity"] in ["default", "composite"]: + self.submodels[ + "electrolyte conductivity" + ] = pybamm.electrolyte_conductivity.Composite(self.param) + elif self.options["electrolyte conductivity"] == "integrated": + self.submodels[ + "electrolyte conductivity" + ] = pybamm.electrolyte_conductivity.Integrated(self.param) + elif self.options["surface form"] == "differential": + raise NotImplementedError( + "surface form '{}' has not been implemented for SPMe yet".format( + self.options["surface form"] + ) + ) + elif self.options["surface form"] == "algebraic": + raise NotImplementedError( + "surface form '{}' has not been implemented for SPMe yet".format( + self.options["surface form"] + ) + ) + self.submodels["electrolyte diffusion"] = pybamm.electrolyte_diffusion.Full( self.param ) diff --git a/pybamm/models/submodels/electrolyte_conductivity/__init__.py b/pybamm/models/submodels/electrolyte_conductivity/__init__.py index 70ba955ff8..04925ea890 100644 --- a/pybamm/models/submodels/electrolyte_conductivity/__init__.py +++ b/pybamm/models/submodels/electrolyte_conductivity/__init__.py @@ -2,5 +2,6 @@ from .leading_order_conductivity import LeadingOrder from .composite_conductivity import Composite from .full_conductivity import Full +from .integrated_conductivity import Integrated from . import surface_potential_form diff --git a/pybamm/models/submodels/electrolyte_conductivity/integrated_conductivity.py b/pybamm/models/submodels/electrolyte_conductivity/integrated_conductivity.py new file mode 100644 index 0000000000..af6f4d075e --- /dev/null +++ b/pybamm/models/submodels/electrolyte_conductivity/integrated_conductivity.py @@ -0,0 +1,173 @@ +# +# Composite electrolyte potential employing integrated Stefan-Maxwell +# +import pybamm +from .base_electrolyte_conductivity import BaseElectrolyteConductivity + + +class Integrated(BaseElectrolyteConductivity): + """ + Integrated model for conservation of charge in the electrolyte derived from + integrating the Stefan-Maxwell constitutive equations, from [1]_. + + Parameters + ---------- + param : parameter class + The parameters to use for this submodel + domain : str, optional + The domain in which the model holds + reactions : dict, optional + Dictionary of reaction terms + + References + ---------- + .. [1] F. Brosa Planella, M. Sheikh, and W. D. Widanage, “Systematic derivation and + validation of reduced thermal-electrochemical models for lithium-ion + batteries using asymptotic methods.” arXiv preprint, 2020. + + **Extends:** :class:`pybamm.electrolyte_conductivity.BaseElectrolyteConductivity` + + """ + + def __init__(self, param, domain=None): + pybamm.citations.register("brosaplanella2020TSPMe") + super().__init__(param, domain) + + def _higher_order_macinnes_function(self, x): + return pybamm.log(x) + + def get_coupled_variables(self, variables): + c_e_av = variables["X-averaged electrolyte concentration"] + + i_boundary_cc_0 = variables["Leading-order current collector current density"] + c_e_n = variables["Negative electrolyte concentration"] + c_e_s = variables["Separator electrolyte concentration"] + c_e_p = variables["Positive electrolyte concentration"] + c_e_n0 = pybamm.boundary_value(c_e_n, "left") + + delta_phi_n_av = variables[ + "X-averaged negative electrode surface potential difference" + ] + phi_s_n_av = variables["X-averaged negative electrode potential"] + + tor_n = variables["Negative electrolyte tortuosity"] + tor_s = variables["Separator tortuosity"] + tor_p = variables["Positive electrolyte tortuosity"] + + T_av = variables["X-averaged cell temperature"] + T_av_n = pybamm.PrimaryBroadcast(T_av, "negative electrode") + T_av_s = pybamm.PrimaryBroadcast(T_av, "separator") + T_av_p = pybamm.PrimaryBroadcast(T_av, "positive electrode") + + param = self.param + l_n = param.l_n + l_p = param.l_p + x_n = pybamm.standard_spatial_vars.x_n + x_s = pybamm.standard_spatial_vars.x_s + x_p = pybamm.standard_spatial_vars.x_p + x_n_edge = pybamm.standard_spatial_vars.x_n_edge + x_p_edge = pybamm.standard_spatial_vars.x_p_edge + + chi_av = param.chi(c_e_av) + chi_av_n = pybamm.PrimaryBroadcast(chi_av, "negative electrode") + chi_av_s = pybamm.PrimaryBroadcast(chi_av, "separator") + chi_av_p = pybamm.PrimaryBroadcast(chi_av, "positive electrode") + + # electrolyte current + i_e_n = i_boundary_cc_0 * x_n / l_n + i_e_s = pybamm.PrimaryBroadcast(i_boundary_cc_0, "separator") + i_e_p = i_boundary_cc_0 * (1 - x_p) / l_p + i_e = pybamm.Concatenation(i_e_n, i_e_s, i_e_p) + + i_e_n_edge = i_boundary_cc_0 * x_n_edge / l_n + i_e_s_edge = pybamm.PrimaryBroadcastToEdges(i_boundary_cc_0, "separator") + i_e_p_edge = i_boundary_cc_0 * (1 - x_p_edge) / l_p + + # electrolyte potential + indef_integral_n = ( + pybamm.IndefiniteIntegral( + i_e_n_edge / (param.kappa_e(c_e_n, T_av_n) * tor_n), x_n + ) + * param.C_e + / param.gamma_e + ) + indef_integral_s = ( + pybamm.IndefiniteIntegral( + i_e_s_edge / (param.kappa_e(c_e_s, T_av_s) * tor_s), x_s + ) + * param.C_e + / param.gamma_e + ) + indef_integral_p = ( + pybamm.IndefiniteIntegral( + i_e_p_edge / (param.kappa_e(c_e_p, T_av_p) * tor_p), x_p + ) + * param.C_e + / param.gamma_e + ) + + integral_n = indef_integral_n + integral_s = indef_integral_s + pybamm.boundary_value(integral_n, "right") + integral_p = indef_integral_p + pybamm.boundary_value(integral_s, "right") + + phi_e_const = ( + -delta_phi_n_av + + phi_s_n_av + - ( + chi_av + * (1 + param.Theta * T_av) + * pybamm.x_average(self._higher_order_macinnes_function(c_e_n / c_e_n0)) + ) + + pybamm.x_average(integral_n) + ) + + phi_e_n = ( + phi_e_const + + ( + chi_av_n + * (1 + param.Theta * T_av_n) + * self._higher_order_macinnes_function(c_e_n / c_e_n0) + ) + - integral_n + ) + + phi_e_s = ( + phi_e_const + + ( + chi_av_s + * (1 + param.Theta * T_av_s) + * self._higher_order_macinnes_function(c_e_s / c_e_n0) + ) + - integral_s + ) + + phi_e_p = ( + phi_e_const + + ( + chi_av_p + * (1 + param.Theta * T_av_p) + * self._higher_order_macinnes_function(c_e_p / c_e_n0) + ) + - integral_p + ) + + # concentration overpotential + eta_c_av = ( + chi_av + * (1 + param.Theta * T_av) + * ( + pybamm.x_average(self._higher_order_macinnes_function(c_e_p / c_e_av)) + - pybamm.x_average(self._higher_order_macinnes_function(c_e_n / c_e_av)) + ) + ) + + # average electrolyte ohmic losses + delta_phi_e_av = -(pybamm.x_average(integral_p) - pybamm.x_average(integral_n)) + + variables.update( + self._get_standard_potential_variables(phi_e_n, phi_e_s, phi_e_p) + ) + variables.update(self._get_standard_current_variables(i_e)) + variables.update(self._get_split_overpotential(eta_c_av, delta_phi_e_av)) + + return variables diff --git a/tests/integration/test_models/test_full_battery_models/test_lithium_ion/test_compare_outputs.py b/tests/integration/test_models/test_full_battery_models/test_lithium_ion/test_compare_outputs.py index fb338965c3..495d605d50 100644 --- a/tests/integration/test_models/test_full_battery_models/test_lithium_ion/test_compare_outputs.py +++ b/tests/integration/test_models/test_full_battery_models/test_lithium_ion/test_compare_outputs.py @@ -15,7 +15,7 @@ def test_compare_outputs_surface_form(self): ] model_combos = [ ([pybamm.lithium_ion.SPM(opt) for opt in options]), - ([pybamm.lithium_ion.SPMe(opt) for opt in options]), + # ([pybamm.lithium_ion.SPMe(opt) for opt in options]), # not implemented ([pybamm.lithium_ion.DFN(opt) for opt in options]), ] diff --git a/tests/integration/test_models/test_full_battery_models/test_lithium_ion/test_spme.py b/tests/integration/test_models/test_full_battery_models/test_lithium_ion/test_spme.py index 1b76aca7e7..151b5c3196 100644 --- a/tests/integration/test_models/test_full_battery_models/test_lithium_ion/test_spme.py +++ b/tests/integration/test_models/test_full_battery_models/test_lithium_ion/test_spme.py @@ -112,14 +112,20 @@ def test_particle_quartic(self): modeltest = tests.StandardModelTest(model) modeltest.test_all() - def test_surface_form_differential(self): - options = {"surface form": "differential"} - model = pybamm.lithium_ion.SPMe(options) - modeltest = tests.StandardModelTest(model) - modeltest.test_all() - - def test_surface_form_algebraic(self): - options = {"surface form": "algebraic"} + # def test_surface_form_differential(self): + # options = {"surface form": "differential"} + # model = pybamm.lithium_ion.SPMe(options) + # modeltest = tests.StandardModelTest(model) + # modeltest.test_all() + + # def test_surface_form_algebraic(self): + # options = {"surface form": "algebraic"} + # model = pybamm.lithium_ion.SPMe(options) + # modeltest = tests.StandardModelTest(model) + # modeltest.test_all() + + def test_integrated_conductivity(self): + options = {"electrolyte conductivity": "integrated"} model = pybamm.lithium_ion.SPMe(options) modeltest = tests.StandardModelTest(model) modeltest.test_all() diff --git a/tests/unit/test_citations.py b/tests/unit/test_citations.py index bc7c70a5a7..a2e243f552 100644 --- a/tests/unit/test_citations.py +++ b/tests/unit/test_citations.py @@ -107,6 +107,15 @@ def test_subramanian_2005(self): pybamm.particle.PolynomialManyParticles(None, "Negative", "quadratic profile") self.assertIn("subramanian2005", citations._papers_to_cite) + def test_brosaplanella_2020(self): + # Test that calling relevant bits of code adds the right paper to citations + citations = pybamm.citations + + citations._reset() + self.assertNotIn("brosaplanella2020TSPMe", citations._papers_to_cite) + pybamm.electrolyte_conductivity.Integrated(None) + self.assertIn("brosaplanella2020TSPMe", citations._papers_to_cite) + def test_scikit_fem(self): citations = pybamm.citations diff --git a/tests/unit/test_models/test_full_battery_models/test_base_battery_model.py b/tests/unit/test_models/test_full_battery_models/test_base_battery_model.py index b50bd1534f..1348f222dd 100644 --- a/tests/unit/test_models/test_full_battery_models/test_base_battery_model.py +++ b/tests/unit/test_models/test_full_battery_models/test_base_battery_model.py @@ -149,6 +149,10 @@ def test_options(self): pybamm.BaseBatteryModel({"particle shape": "bad particle shape"}) with self.assertRaisesRegex(pybamm.OptionError, "operating mode"): pybamm.BaseBatteryModel({"operating mode": "bad operating mode"}) + with self.assertRaisesRegex(pybamm.OptionError, "electrolyte conductivity"): + pybamm.BaseBatteryModel( + {"electrolyte conductivity": "bad electrolyte conductivity"} + ) # SEI options with self.assertRaisesRegex(pybamm.OptionError, "sei"): diff --git a/tests/unit/test_models/test_full_battery_models/test_lithium_ion/test_dfn.py b/tests/unit/test_models/test_full_battery_models/test_lithium_ion/test_dfn.py index 7088c3f0e9..326ea471ed 100644 --- a/tests/unit/test_models/test_full_battery_models/test_lithium_ion/test_dfn.py +++ b/tests/unit/test_models/test_full_battery_models/test_lithium_ion/test_dfn.py @@ -118,6 +118,11 @@ def test_surface_form_algebraic(self): model = pybamm.lithium_ion.DFN(options) model.check_well_posedness() + def test_electrolyte_options(self): + options = {"electrolyte conductivity": "integrated"} + with self.assertRaisesRegex(pybamm.OptionError, "electrolyte conductivity"): + pybamm.lithium_ion.DFN(options) + class TestDFNWithSEI(unittest.TestCase): def test_well_posed_constant(self): diff --git a/tests/unit/test_models/test_full_battery_models/test_lithium_ion/test_spm.py b/tests/unit/test_models/test_full_battery_models/test_lithium_ion/test_spm.py index 460d711825..808549695a 100644 --- a/tests/unit/test_models/test_full_battery_models/test_lithium_ion/test_spm.py +++ b/tests/unit/test_models/test_full_battery_models/test_lithium_ion/test_spm.py @@ -119,6 +119,11 @@ def test_surface_form_algebraic(self): model = pybamm.lithium_ion.SPM(options) model.check_well_posedness() + def test_electrolyte_options(self): + options = {"electrolyte conductivity": "full"} + with self.assertRaisesRegex(pybamm.OptionError, "electrolyte conductivity"): + pybamm.lithium_ion.SPM(options) + def test_new_model(self): model = pybamm.lithium_ion.SPM({"thermal": "x-full"}) new_model = model.new_copy() diff --git a/tests/unit/test_models/test_full_battery_models/test_lithium_ion/test_spme.py b/tests/unit/test_models/test_full_battery_models/test_lithium_ion/test_spme.py index 41579dad6b..d6ef44122d 100644 --- a/tests/unit/test_models/test_full_battery_models/test_lithium_ion/test_spme.py +++ b/tests/unit/test_models/test_full_battery_models/test_lithium_ion/test_spme.py @@ -110,14 +110,24 @@ def test_particle_shape_user(self): def test_surface_form_differential(self): options = {"surface form": "differential"} - model = pybamm.lithium_ion.SPMe(options) - model.check_well_posedness() + with self.assertRaises(NotImplementedError): + pybamm.lithium_ion.SPMe(options) def test_surface_form_algebraic(self): options = {"surface form": "algebraic"} + with self.assertRaises(NotImplementedError): + pybamm.lithium_ion.SPMe(options) + + def test_integrated_conductivity(self): + options = {"electrolyte conductivity": "integrated"} model = pybamm.lithium_ion.SPMe(options) model.check_well_posedness() + def test_electrolyte_options(self): + options = {"electrolyte conductivity": "full"} + with self.assertRaisesRegex(pybamm.OptionError, "electrolyte conductivity"): + pybamm.lithium_ion.SPMe(options) + class TestSPMeWithSEI(unittest.TestCase): def test_well_posed_reaction_limited(self): diff --git a/tests/unit/test_models/test_submodels/test_electrolyte_conductivity/test_integrated.py b/tests/unit/test_models/test_submodels/test_electrolyte_conductivity/test_integrated.py new file mode 100644 index 0000000000..84554d68eb --- /dev/null +++ b/tests/unit/test_models/test_submodels/test_electrolyte_conductivity/test_integrated.py @@ -0,0 +1,42 @@ +# +# Test integrated Stefan Maxwell electrolyte conductivity submodel +# + +import pybamm +import tests +import unittest + + +class TestFull(unittest.TestCase): + def test_public_functions(self): + param = pybamm.LithiumIonParameters() + a = pybamm.PrimaryBroadcast(0, "current collector") + c_e_n = pybamm.standard_variables.c_e_n + c_e_s = pybamm.standard_variables.c_e_s + c_e_p = pybamm.standard_variables.c_e_p + variables = { + "X-averaged electrolyte concentration": a, + "Leading-order current collector current density": a, + "Negative electrolyte concentration": c_e_n, + "Separator electrolyte concentration": c_e_s, + "Positive electrolyte concentration": c_e_p, + "X-averaged negative electrode surface potential difference": a, + "X-averaged negative electrode potential": a, + "Negative electrolyte tortuosity": a, + "Separator tortuosity": a, + "Positive electrolyte tortuosity": a, + "X-averaged cell temperature": a, + } + submodel = pybamm.electrolyte_conductivity.Integrated(param) + std_tests = tests.StandardSubModelTests(submodel, variables) + std_tests.test_all() + + +if __name__ == "__main__": + print("Add -v for more debug output") + import sys + + if "-v" in sys.argv: + debug = True + pybamm.settings.debug_mode = True + unittest.main()