Comments (3)
The Jacobian for the ODE system sys
is the matrix J[i,j] = Derivative(sys.dvs[j])*sys.eqs[i]
, i.e. the derivative of the i
th equation by the j
th dependent variable. The Rosenbrock W
is the matrix
M - γJ
# Transformed
M/γ - J
those are two different versions, and some ODE solvers use the former while others use the latter. γ
is just some input constant and M
is the mass matrix. The mass matrix is the matrix for Mu' = f(t,u)
in vector notation, so normally an ODE just has M = I
unless explicitly stated.
That's an intermediate step to the calculation of W^(-1)
which is what the solvers actually want. We can also looking into just solving for the components of qrfact(W)
. If our Jacobian
is just represented by a matrix of operations, then generic routines should directly give us this results, and then we would want to run simplification routines on it (Julia's compiler automatically does some if we @fastmath
so that's an option to add as well).
For now we should make their computation explicit, i.e. add in extra fields and let the user do calculate_jacobian!(sys)
, etc., and then add a caclulate_performance_functions!(sys)
that does them all. Then finally after we have all of that together, we can do an operation check on the Jacobian and calculate W^(-1)
only when it's appropriate, i.e. when J
is sufficiently small or sufficiently sparse. I am not sure what a good heuristic is there (ParameterizedFunctions.jl just does "try it and see if it fails"), so it'll take some testing which is why I am saying that should be done last.
This is the last issue for becoming feature-complete with ParameterizedFunctions.jl
from modelingtoolkit.jl.
Jacobians are working. W is working. Inversion is all that's left.
from modelingtoolkit.jl.
Inversion is working. We need better simplification routines but it does work.
from modelingtoolkit.jl.
Related Issues (20)
- Ambiguous methods for operations involving `DynamicQuantities.Quantity` and `Num`
- Remaking ODEProblem fails inside of Turing model
- Remaking ODEproblem causes call to `solve` to fail on remade problem HOT 1
- remake with use_defaults=true fails when defaults contain non-trivial expressions
- Systems are considered equal, even if they have different events
- `SymbolicDiscreteCallback` and `SymbolicContiniuousCallback` have different affect field names
- Solve fails after remake inside of Turing model.
- Missing metadata getters
- Cannot add both default value and description to variables created in multiline statements (but parameters work). HOT 2
- Inconsistency with scalarisation of MTK states and parameters HOT 2
- Performant way to remake ODEProblem with updated external input function? HOT 2
- Remake fails with simple parameter dict HOT 1
- Allow altering a symbolic parameter default value after creation.
- Improve printing/display of `XSystem` parameters
- Is `remake`ing an `ODEProblem` with a symbolic map of `u0` or `p` type-stable? HOT 5
- Guesses for symbolic vector variables are incorrect
- Support arbitrarily nested structural parameter conditions
- Parameters (and probably variables) occurring in events only are not inferred into ODESystems HOT 2
- remake failing for several cases with vector variables
- Problem creating problems for vector variables/parameters HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from modelingtoolkit.jl.