Skip to content

CompatHelper: bump compat for ModelingToolkit to 10, (keep existing compat) #129

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ DocStringExtensions = "0.9"
InteractiveUtils = "1.10"
Latexify = "0.16"
LinearAlgebra = "1.10"
ModelingToolkit = "8.74, 9"
ModelingToolkit = "10"
Reexport = "1"
SciMLBase = "2.15"
SpecialFunctions = "2"
Expand Down
8 changes: 4 additions & 4 deletions src/ode_def_opts.jl
Original file line number Diff line number Diff line change
Expand Up @@ -77,13 +77,13 @@ function ode_def_opts(name::Symbol, opts::Dict{Symbol, Bool}, curmod, ex::Expr,

mtk_diffeqs = [D(vars[i]) ~ mtk_ops[i] for i in 1:length(vars)]

sys = ODESystem(mtk_diffeqs, t, vars, params, name = gensym(:Parameterized))
sys = System(mtk_diffeqs, t, vars, params, name = gensym(:Parameterized))

f_ex_oop, f_ex_iip = ModelingToolkit.generate_function(sys, vars, params)
f_ex_oop, f_ex_iip = ModelingToolkit.generate_rhs(sys)

if opts[:build_tgrad]
try
tgrad_ex_oop, tgrad_ex_iip = ModelingToolkit.generate_tgrad(sys, vars, params)
tgrad_ex_oop, tgrad_ex_iip = ModelingToolkit.generate_tgrad(sys)
catch
@warn "tgrad construction failed"
tgrad_ex_oop, tgrad_ex_iip = nothing, nothing
Expand All @@ -94,7 +94,7 @@ function ode_def_opts(name::Symbol, opts::Dict{Symbol, Bool}, curmod, ex::Expr,

if opts[:build_jac]
try
J_ex_oop, J_ex_iip = ModelingToolkit.generate_jacobian(sys, vars, params)
J_ex_oop, J_ex_iip = ModelingToolkit.generate_jacobian(sys)
catch
@warn "Jacobian construction failed"
J_ex_oop, J_ex_iip = nothing, nothing
Expand Down
Loading