File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
src/structural_transformation Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -104,7 +104,7 @@ These equations matches generated numerical code.
104
104
105
105
See also [`equations`](@ref) and [`ModelingToolkit.get_eqs`](@ref).
106
106
"""
107
- function full_equations (sys:: AbstractSystem ; simplify = false )
107
+ function full_equations (sys:: AbstractSystem ; simplify = false , allow_singular = false )
108
108
empty_substitutions (sys) && return equations (sys)
109
109
substitutions = get_substitutions (sys)
110
110
substitutions. subed_eqs === nothing || return substitutions. subed_eqs
@@ -119,7 +119,7 @@ function full_equations(sys::AbstractSystem; simplify = false)
119
119
eq = 0 ~ eq. rhs - eq. lhs
120
120
end
121
121
rhs = tearing_sub (eq. rhs, solved, simplify)
122
- if rhs isa Symbolic
122
+ if rhs isa Symbolic || allow_singular
123
123
return 0 ~ rhs
124
124
else # a number
125
125
error (" tearing failed because the system is singular" )
You can’t perform that action at this time.
0 commit comments