You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
ODE.jl is slowly being phased out, so for performance I would suggest switching to DifferentialEquations.jl. DifferentialEquations.jl has a low dependency mode so that way you don't need to depend on everything at once. Instead of ode45(f,u0,tspan;kwargs...), you can simply translate things to sol = solve(ODEProblem(f,u0,tspan),Tsit5();kwargs) and then use the sol type.
Doing it like this, you only need a dependency on using DiffEqBase, OrdinaryDiffEq. DiffEqBase was in ODE.jl anyways, and OrdinaryDiffEq.jl is the new solver you're using. This setup also gives you access to a whole load of other algorithms as well if you wanted the user to pass in the algorithm type. Note that here tspan must be a tuple and the types are respected, so a change to tspan = (0.0,1.0) instead of tspan = [0,1] is required.
If you're interested, I'll setup the PR.
The text was updated successfully, but these errors were encountered:
ODE.jl is slowly being phased out, so for performance I would suggest switching to DifferentialEquations.jl. DifferentialEquations.jl has a low dependency mode so that way you don't need to depend on everything at once. Instead of
ode45(f,u0,tspan;kwargs...)
, you can simply translate things tosol = solve(ODEProblem(f,u0,tspan),Tsit5();kwargs)
and then use thesol
type.Doing it like this, you only need a dependency on
using DiffEqBase, OrdinaryDiffEq
. DiffEqBase was in ODE.jl anyways, and OrdinaryDiffEq.jl is the new solver you're using. This setup also gives you access to a whole load of other algorithms as well if you wanted the user to pass in the algorithm type. Note that heretspan
must be a tuple and the types are respected, so a change totspan = (0.0,1.0)
instead oftspan = [0,1]
is required.If you're interested, I'll setup the PR.
The text was updated successfully, but these errors were encountered: