Closed hexaeder closed 1 week ago
Was this fixed? On MTK v9.49:
using ModelingToolkit
@independent_variables t
@parameters a [guess=2]
@variables x(t) [guess=1]
@named sys = ODESystem([x ~ a], t)
guesses(sys)
Dict{Any, Any} with 2 entries:
a => 2
x(t) => 1
using ModelingToolkitStandardLibrary.Blocks
@mtkmodel MyMod begin
@components begin
a = RealInput(guess=1)
end
@parameters begin
b, [guess=2]
end
end
@named model = MyMod()
guesses(model)
Dict{Any, Any} with 2 entries:
a₊u(t) => 1
b => 2
Yep, seems fixed. I tried to find the corresponding PR, but no luck.
Describe the bug 🐞
If you attach a guess to a parameter, it isn't reflected in the
guesses
of the systemExpected behavior
Have
guesses
contain all guesses.Minimal Reproducible Example 👇 Example 1:
Example 2:
Environment (please complete the following information):
using Pkg; Pkg.status()