Skip to content

Commit

Permalink
fix: handle non-symbolic and nothing u0 for DiscreteProblem
Browse files Browse the repository at this point in the history
  • Loading branch information
AayushSabharwal committed Sep 19, 2024
1 parent e855035 commit bbc8bf7
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/systems/discrete_system/discrete_system.jl
Original file line number Diff line number Diff line change
Expand Up @@ -247,6 +247,13 @@ function process_DiscreteProblem(constructor, sys::DiscreteSystem, u0map, paramm
dvs = unknowns(sys)
ps = parameters(sys)

if eltype(u0map) <: Number
u0map = unknowns(sys) .=> vec(u0map)
end
if u0map === nothing || isempty(u0map)
u0map = Dict()
end

trueu0map = Dict()
for (k, v) in u0map
k = unwrap(k)
Expand Down

0 comments on commit bbc8bf7

Please sign in to comment.