Skip to content

Commit 2b9d6f0

Browse files
authored
don't balance systems with rational coefficients (#670)
1 parent cd46c63 commit 2b9d6f0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/types/conversion.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ function Base.convert(::Type{StateSpace}, G::TransferFunction{TE,<:SisoTf{T0}};
8787
end
8888

8989
# Note: balancing is only applied by default for floating point types, integer systems are not balanced since that would change the type.
90-
function Base.convert(::Type{StateSpace{TE,T}}, G::TransferFunction; balance=!(T <: Integer)) where {TE,T<:Number}
90+
function Base.convert(::Type{StateSpace{TE,T}}, G::TransferFunction; balance=!(T <: Union{Integer, Rational})) where {TE,T<:Number}
9191
if !isproper(G)
9292
error("System is improper, a state-space representation is impossible")
9393
end

0 commit comments

Comments
 (0)