Closed franckgaga closed 12 months ago
Hi,
It seems that the : operator for indexing all the elements does not work on TransferFunction. These lines:
:
TransferFunction
sys = append(tf(2, [10, 1]), tf(3, [5, 1])) sys[:, 1]
results in:
ERROR: MethodError: no method matching length(::Colon) Closest candidates are: length(::Union{Base.KeySet, Base.ValueIterator}) @ Base abstractdict.jl:58 length(::Union{SparseArrays.FixedSparseVector{Tv, Ti}, SparseArrays.SparseVector{Tv, Ti}} where {Tv, Ti}) @ SparseArrays ~/.julia/juliaup/julia-1.9.3+0.x64.linux.gnu/share/julia/stdlib/v1.9/SparseArrays/src/sparsevector.jl:95 length(::Union{IterTools.Properties, IterTools.PropertyValues}) @ IterTools ~/.julia/packages/IterTools/CtkIT/src/IterTools.jl:1010 ... Stacktrace: [1] getindex(::TransferFunction{Continuous, ControlSystemsBase.SisoRational{Int64}}, ::Function, ::Int64) @ ControlSystemsBase ~/.julia/packages/ControlSystemsBase/X6e5r/src/types/TransferFunction.jl:58 [2] top-level scope @ REPL[10]:1
Thanks !
Francis Gagnon
Thanks Fredrik!
Hi,
It seems that the
:
operator for indexing all the elements does not work onTransferFunction
. These lines:results in:
Thanks !
Francis Gagnon