Skip to content

Commit

Permalink
fix: reorder system in SCCNonlinearProblem
Browse files Browse the repository at this point in the history
  • Loading branch information
AayushSabharwal committed Nov 30, 2024
1 parent 10de62b commit c5f6b30
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/systems/nonlinear/nonlinearsystem.jl
Original file line number Diff line number Diff line change
Expand Up @@ -703,6 +703,10 @@ function SciMLBase.SCCNonlinearProblem{iip}(sys::NonlinearSystem, u0map,
push!(subprobs, prob)
end

new_dvs = dvs[reduce(vcat, var_sccs)]
new_eqs = eqs[reduce(vcat, eq_sccs)]
@set! sys.unknowns = new_dvs
@set! sys.eqs = new_eqs
return SCCNonlinearProblem(subprobs, explicitfuns, sys, p)
end

Expand Down

0 comments on commit c5f6b30

Please sign in to comment.