Skip to content

Commit e4d10cc

Browse files
committed
Add test
1 parent c882b62 commit e4d10cc

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

test/odesystem.jl

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -849,3 +849,17 @@ let
849849
D(sys.x) ~ sys.v]
850850
@test isequal(full_equations(sys_simp), true_eqs)
851851
end
852+
853+
let
854+
@variables t
855+
@variables x(t) = 1
856+
@variables y(t) = 1
857+
@parameters pp = -1
858+
der = Differential(t)
859+
@named sys4 = ODESystem([der(x) ~ -y; der(y) ~ 1 - y + x], t)
860+
as = alias_elimination(sys4)
861+
@test length(equations(as)) == 1
862+
@test isequal(equations(as)[1].lhs, -der(der(x)))
863+
# TODO: maybe do not emit x_t
864+
@test_nowarn sys4s = structural_simplify(sys4)
865+
end

0 commit comments

Comments
 (0)