Skip to content

Commit b24332b

Browse files
authored
Merge pull request #122 from JuliaControl/mtk_compat
Add compat details on MTK.jl bugfixes
2 parents 3833301 + 4fda91d commit b24332b

File tree

2 files changed

+5
-7
lines changed

2 files changed

+5
-7
lines changed

docs/Project.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,4 +16,4 @@ JuMP = "1"
1616
LinearAlgebra = "1.6"
1717
Logging = "1.6"
1818
Plots = "1"
19-
ModelingToolkit = "~9.41"
19+
ModelingToolkit = "9.50"

docs/src/manual/mtk.md

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ the last section.
2323
will work for all corner cases.
2424

2525
!!! compat
26-
The example only work with `ModelingToolkit.jl` v9.41 releases.
26+
The example relies on features and bugfixes of `ModelingToolkit.jl` v9.50.
2727

2828
We first construct and instantiate the pendulum model:
2929

@@ -79,16 +79,14 @@ function generate_f_h(model, inputs, outputs)
7979
end
8080
return nothing
8181
end
82-
return_inplace = true
8382
(_, h_ip) = ModelingToolkit.build_explicit_observed_function(
84-
io_sys, outputs; inputs, return_inplace
83+
io_sys, outputs; inputs, return_inplace = true
8584
)
86-
println(h_ip)
8785
u_nothing = fill(nothing, nu)
8886
function h!(y, x, _ , p)
8987
try
90-
# MTK.jl supports a `u` argument in `h_` function but not this package. We set
91-
# `u` as a vector of nothing and `h_` function will presumably throw an
88+
# MTK.jl supports a `u` argument in `h_ip` function but not this package. We set
89+
# `u` as a vector of nothing and `h_ip` function will presumably throw an
9290
# MethodError it this argument is used inside the function
9391
h_ip(y, x, u_nothing, p, nothing)
9492
catch err

0 commit comments

Comments
 (0)