-
Notifications
You must be signed in to change notification settings - Fork 89
Broadcasting addition for mimo systems #416
Description
As mentioned by @olof3 in #166 we currently have that addition works between mimo system and scalars. Addition of scalar matrices also works, but broadcasting does not work.
ss(-ones(2,2), ones(2,2), ones(2,2), zeros(2,2)) + 1 # A, Works
ss(-ones(2,2), ones(2,2), ones(2,2), zeros(2,2)) + ones(2, 2) # B, Works
ss(-ones(2,2), ones(2,2), ones(2,2), zeros(2,2)) .+ 1 # C, Does not work
This operation has to mean that one wants to add something to the D matrix (or equivalently to the matrix of transfer functions) which means we are doing matrix-scalar addition in the mimo case, and it just seems a bit off that we handle it differently then the rest of the julia ecosystem.
I see the problem that we represent a siso system as a 1x1 array of systems and then that would also fall into the same category of matrix-scalar addition, so I'm not sure what would be the nicest solution.
Works fine as it is now so I'm in no hurry to do anything about it, but thought I would document it since I closed the old issue.