Skip to content
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

Limits for inputs to functions #15

Open
valentinsulzer opened this issue Dec 9, 2022 · 2 comments
Open

Limits for inputs to functions #15

valentinsulzer opened this issue Dec 9, 2022 · 2 comments

Comments

@valentinsulzer
Copy link

Could/should limits be specified by the BPX for inputs into functions? e.g. concentration between 0 and 3 molar, temperature between 10 and 40 Celsius. See pybamm-team/PyBaMM#989

@brosaplanella
Copy link

This ties into this PyBaMM issue

@ejfdickinson
Copy link
Collaborator

ejfdickinson commented Jun 2, 2023

An alternative short-term route, that places this more in the hands of the user, would be to put a note in the specification that encourages regions of validity and means of extrapolation to be expressed explicitly in the functional form. So:

U =
    (x < 0.99)*(x > 0.01)*complicated_function(min(0.99,max(x,0.01))) +
    (x > 0.99)*upper_extrapolated_function(x) +
    (x < 0.01)*lower_extrapolated_function(x)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants