Closed
Description
Currently, multiplying a SISO TransferFunction
object by a NumPy array results in a dimension error:
import control
import numpy as np
tf = control.TransferFunction([1], [1, 0])
arr = np.array([
[1, 0],
[2, 1],
])
print(tf * arr)
print(arr * tf)
ValueError: C = A * B: A has 1 column(s) (input(s)), but B has 2 row(s) (output(s)).
I think it would be convenient if output was a MIMO TransferFunction
object of the array's dimension. So, for example,
G = control.TransferFunction(
[
[[1], [0]],
[[2], [1]],
],
[
[[1, 0], [1, 0]],
[[1, 0], [1, 0]],
],
)
I would be happy to implement this and do a PR, but I want to make sure it's something the maintainers actually want. I would think all SISO systems (state-space, etc) should behave in the same way.
This appears to have been discussed in #459 , but I'm not sure what the conclusion was.
Metadata
Metadata
Assignees
Labels
No labels