-
-
Notifications
You must be signed in to change notification settings - Fork 546
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Bug]: Noise in low-current results using O'Kane 2022 parameter set due to graphite OCP interpolation from csv file #4365
Comments
can you try using a linear interpolant rather than a cubic one? something like parameter_values = pybamm.ParameterValues("Okane2022")
path = # path to where the csv is stored
graphite_LGM50_ocp_Chen2020_data = pybamm.parameters.process_1D_data(
"graphite_LGM50_ocp_Chen2020.csv", path=path
)
def graphite_LGM50_ocp_Chen2020(sto):
name, (x, y) = graphite_LGM50_ocp_Chen2020_data
return pybamm.Interpolant(x, y, sto, name=name, interpolator="linear")
parameter_values["Negative electrode OCP [V]"] = graphite_LGM50_ocp_Chen2020 I think all the data interpolant OCPs should be linear, but it looks like they aren't... |
Yes so the results may be dependent on the interpolator (thanks @kratman for looking into this), my question I think is more fundamental. To my understanding:
I raised this issue to suggest that the |
Yeah I used the Ai2020 data to show that something was specifically an issue with the data set used by OKane2022. It could be as simple as not having enough resolution to make the function smooth |
@DrSOKane Can you take a look at this? |
PyBaMM Version
24.5
Python Version
3.11.7
Describe the bug
Differentiating low c-rate constant-current results reveals noise in calculated voltage when using
"OKane2022"
parameter set, but not when using"Chen2020"
parameter set:This is due to the csv interpolation used for the graphite OCP in the
"OKane2022"
parameter set. The suggested fix would be to replace this with the functional form defined in"Chen2020"
, as the OCP curves for these parameter sets should be identical anyway.Steps to Reproduce
The following code uses the Chen2020 parameters, OKane2022 parameters and finally the OKane2022 parameters with the graphite OCP parameter replaced with the value in the Chen2020 parameter set:
Relevant log output
The text was updated successfully, but these errors were encountered: