Catalyst.jl
Catalyst.jl copied to clipboard
Support for delays
I have a biological model that has a few explicit delays that mean I need to use the DDE functionality of JuliaDiffEq. I checked on the gitter.im and was told DiffEqBiological doesn't support this stops me being able to use DiffEqBiological for now.
@ChrisRackauckas Does Modeling Toolkit support generating ODEs with delays now? This might be a good reason to add MT output (at least start prototyping it).
It doesn't, but it would be quite easy to do now. It's one of the reasons for making variables functions.
I'm thinking that for now we can just have a separate method that gets applied to a reaction network to generate a MT model. As the simplification picture improves then we could switch the backend over to it. This would at least give users a way to start accessing MT features and code generation. If the generated models benchmark comparably to the DEBio generated ODEs we could then fully switch over the ODE code...
Agreed that we at some point we have to think of moving stuff over to MT, been holding it off for quite a while waiting for MT to get more and more developed. It feels like the transition (and later updates to synch with new MT features) get easier the later on we can do it? But maybe it is time to do something now-ish?
I was waiting on expression simplification, which I think is a current priority, but not really implemented yet. But I see no reason we couldn't write a separate code path to generate MT models now, and just swap it in later when simplification gets added (or if we find that the ODEs generated from the MT model end up having similar performance despite not having expression simplification).
I've been moving things slowly in this direction. Sparsity support was added last week. I need to do +
splitting and SDE support, and I'll add an arrow notation. But I don't think expression simplification is really the hold up.
Just a polite and curious poke to see if you folks have taken this any further?
I'm not aware that this is supported in ModelingToolkit yet, but if it is for DDEs we could add it here.
For jump models there is https://github.com/palmtree2013/DelaySSAToolkit.jl which can simulate delay SSAs, adding delays into a non-delay Catalyst model.
DDEs working great! Would love to see it here too one day to have more in the toolbox .. well more like a full-on platform now. Will use DelaySSAToolkit.jl if that is what you recommend. thx
Sorry, are you saying DDEs now work in ModelingToolkit? If so, can you point me to an example?
whoops, was referring to: https://diffeq.sciml.ai/stable/tutorials/dde_example/#Delay-Differential-Equations
On Tue, Aug 2, 2022 at 2:58 PM Sam Isaacson @.***> wrote:
Sorry, are you saying DDEs now work in ModelingToolkit? If so, can you point me to an example?
— Reply to this email directly, view it on GitHub https://github.com/SciML/Catalyst.jl/issues/188#issuecomment-1203044667, or unsubscribe https://github.com/notifications/unsubscribe-auth/AATUQOIBUO6KSNHDVDTEPULVXFOUVANCNFSM4LBGKHCA . You are receiving this because you commented.Message ID: <SciML/Catalyst. @.***>
Yeah, once it is supported in ModelingToolkit it will hopefully be straightforward to add here too.
@ChrisRackauckas pointed out delays (constant only?) are supported via the System
type. That being the case we should consider adding a conversion to that type, and a corresponding DDEProblem
support.