Issues interpolating current function and refining parameters #2344
-
Question 1DescriptionI want to use real-life data from a battery storage to model its batteries for synthetic data generation. timescale = param.evaluate(model.timescale)
current_function = pybamm.Interpolant(x=data.index.total_seconds().values,y=-data.current.values,children=timescale * pybamm.t, interpolator='cubic spline') Where time is in 1-second steps, and current is given in Ampere. The latter has to be inverted, to match convention. The current curve is shown below: ProblemThe resulting interpolation just slightly resembles the given data, as seen below: current workaroundI have found, that multiplying the timescale term by some number >> 1 helps to match data much better, but I doubt that this is the best solution. current_function = pybamm.Interpolant(...,children=MULTIPLYER*timescale * pybamm.t, ...) Which yields for MULTIPLYER = 10: RequestIs there any less improvised way to make the current interpolation better, or do I make a substantial mistake beforehand? Question 2DescriptionI know which cells are used in the battery storage, but the data sheet is very brief (I know it's a NMC(333)/C pouch cell, and its size), so I have to rely on PyBamm's parameter sets for most of the time. The default solution is an OK approximation, but I have a pretty big dataset, so I thought I could try refining given parameter sets to my system. This is the result, for adapted electrode sizes: But it used a bad current interpolant: My approach is the following:
With this approach, I get parameter maps like this: ProblemIt is still not fully clear to me, which parameters are most relevant for the optimization. I cannot verify if my refinement uses valid models/current interpolant as I have to generate them on the fly. Current "best" parameter set makes it look worse: cathode_thickness_scale = 1.9
separator_thickness_scale = 2.1
windings = 40
temperature = 290
porosity = 0.5 currently changed/refined parameters 'Nominal cell capacity [A.h]' : 37,
'Electrode height [m]': 0.188,
'Electrode width [m]': 0.171*windings,
'Negative electrode thickness [m]': anode_thickness_scale*param['Negative electrode thickness [m]'],
'Positive electrode thickness [m]': cathode_thickness_scale*param['Positive electrode thickness [m]'],
'Cell volume [m3]': 3.5e-4,
'Upper voltage cut-off [V]': 4.2,
'Lower voltage cut-off [V]': 2.5,
'Number of cells connected in series to make a battery': 100,
'Separator thickness [m]': separator_thickness_scale*param['Separator thickness [m]'],
'Negative particle radius [m]': negative_particle_scaler * param['Negative particle radius [m]'],
'Positive particle radius [m]': positive_particle_scaler * param['Positive particle radius [m]'],
'Ambient temperature [K]': temperature,
'Negative electrode active material volume fraction': anode_AM_vol,
'Positive electrode active material volume fraction': cathode_AM_vol,
'Positive electrode porosity': porosity,
'Negative electrode porosity': porosity request
|
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 4 replies
-
Fitting electrochemical models to data is a task big enough that there are plans to make a Python library for that. And even then, that can not work with a battery that may be arbitrarily different from the Mohtat2020 dataset. You should work from what you know about your specific battery, without any of PyBaMM's standard parameter sets. You may use https://liiondb.com/ for that. That will leave large gaps in your model parameter set, of course. Those you can systematically fill with the help of this paper: An asymptotic derivation of a single particle model with electrolyte You will see that the model parameters collapse into fewer non-dimensionalized ones. Any combination of parameters that generates the same set of non-dimensionalized parameters will look the same in the simulation. |
Beta Was this translation helpful? Give feedback.
Fitting electrochemical models to data is a task big enough that there are plans to make a Python library for that. And even then, that can not work with a battery that may be arbitrarily different from the Mohtat2020 dataset.
You should work from what you know about your specific battery, without any of PyBaMM's standard parameter sets. You may use https://liiondb.com/ for that. That will leave large gaps in your model parameter set, of course. Those you can systematically fill with the help of this paper:
An asymptotic derivation of a single particle model with electrolyte
You will see that the model parameters collapse into fewer non-dimensionalized ones. Any combination of parameters …