Skip to content

Commit 5938b44

Browse files
authored
Merge pull request #880 from SciML/myb/fix_int
Fix linear equation finding
2 parents c868bf1 + ab32e8b commit 5938b44

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/systems/systemstructure.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -196,11 +196,11 @@ function find_linear_equations(sys)
196196
if !(c isa Symbolic) && c isa Number
197197
if isinteger(c)
198198
c = convert(Integer, c)
199+
linear_term += c * var
200+
push!(coeffs, c)
199201
else
200202
all_int_algvars = false
201203
end
202-
linear_term += c * var
203-
push!(coeffs, c)
204204
end
205205
end
206206

0 commit comments

Comments
 (0)