Replies: 1 comment
-
We're working on improving the getting started examples for new models but here's an example that might help. If you want to solve the system
you would do it as x = Variable("x")
y = Variable("y")
model.rhs = {x: x*y}
model.algebraic = {y: x + y} In the algebraic dictionary, the key doesn't connect directly to the equation, it just says "this is the equation for the variable y which is governed by an algebraic equation" |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi I'm Nils and really new to PyBaMM,
I am working on High Temperature Sodium Batteries and would like to implement a model by using BaseModel as a start.
What I don't understand is the "workflow" behind the model.algebraic{} or model.rhs{}.
How does it work in PyBaMM and what does the following part mean exactly?
From documentation:
A dictionary that maps expressions (variables) to expressions that represent the algebraic equations. The algebraic expressions are assumed to equate to zero. Note that all the variables in the model must exist in the keys of rhs or algebraic.
I hope someone can help me with that so I can get more into PyBaMM.
Thank you :)
Beta Was this translation helpful? Give feedback.
All reactions