Skip to content

Commit 52cace3

Browse files
committed
Check consistency before index lowering
1 parent 5a832ec commit 52cace3

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/systems/abstractsystem.jl

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -906,11 +906,12 @@ function will be applied during the tearing process.
906906
function structural_simplify(sys::AbstractSystem; simplify=false)
907907
sys = expand_connections(sys)
908908
sys = alias_elimination(sys)
909+
state = TearingState(sys)
910+
check_consistency(state)
909911
if sys isa ODESystem
910912
sys = dae_index_lowering(ode_order_lowering(sys))
911913
end
912914
state = TearingState(sys)
913-
check_consistency(state)
914915
find_solvables!(state)
915916
sys = tearing_reassemble(state, tearing(state), simplify=simplify)
916917
fullstates = [map(eq->eq.lhs, observed(sys)); states(sys)]

0 commit comments

Comments
 (0)