Skip to content

Commit

Permalink
remove duplicated parameters
Browse files Browse the repository at this point in the history
  • Loading branch information
brosaplanella committed Apr 8, 2024
1 parent d4bf431 commit edb5e18
Showing 1 changed file with 5 additions and 28 deletions.
33 changes: 5 additions & 28 deletions examples/scripts/gitt.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@
import pybop

# Define model
original_parameters = pybop.ParameterSet.pybamm("Xu2019")
parameter_set = pybop.ParameterSet.pybamm("Xu2019")
model = pybop.lithium_ion.SPM(
parameter_set=original_parameters, options={"working electrode": "positive"}
parameter_set=parameter_set, options={"working electrode": "positive"}
)

# Generate data
Expand All @@ -25,35 +25,12 @@
)

# Define parameter set
parameter_set = pybamm.ParameterValues(
parameter_set.update(
{
"Reference OCP [V]": 4.1821,
"Derivative of the OCP wrt stoichiometry [V]": -1.38636,
"Current function [A]": original_parameters["Current function [A]"],
"Number of electrodes connected in parallel to make a cell": original_parameters[
"Number of electrodes connected in parallel to make a cell"
],
"Electrode width [m]": original_parameters["Electrode width [m]"],
"Electrode height [m]": original_parameters["Electrode height [m]"],
"Positive electrode active material volume fraction": original_parameters[
"Positive electrode active material volume fraction"
],
"Positive electrode porosity": original_parameters[
"Positive electrode porosity"
],
"Positive particle radius [m]": original_parameters[
"Positive particle radius [m]"
],
"Positive electrode thickness [m]": original_parameters[
"Positive electrode thickness [m]"
],
"Positive electrode diffusivity [m2.s-1]": original_parameters[
"Positive electrode diffusivity [m2.s-1]"
],
"Maximum concentration in positive electrode [mol.m-3]": original_parameters[
"Maximum concentration in positive electrode [mol.m-3]"
],
}
},
check_already_exists=False,
)

# Define the cost to optimise
Expand Down

0 comments on commit edb5e18

Please sign in to comment.