When converting my ODESystem
into an ODEProblem
to be solved, I find that the full equations are not simplified enough, leading to numerical errors. In particular, one part of the equations looks like this:
Differential(t)(X(t)) ~ exp(a * log(b * X(t)))
This log(...)
is causing problems with negative values, when really this can be simplified to (b * X(t))^a
so that there aren’t any domain issues.
I found I can simplify the symbolic equations further using a symbolic rewriter from SymbolicUtils.jl. However, I’m not sure what to do from here.
Can I structurally simplify the ODESystem with my own additional rules, or can I supply my own equations to the solver?
Thanks