this is a compact way to express 1 transfer function with 3 inputs and convert it to a state space representation.You can find this also as an similar example in the documentation of tf function for the case of 2 outputs. Consider:
>> sys = tf({1,1,1},{[1 .5 1],[1 1],[.7 .5 1]})
sys =
From input 1 to output:
1
---------------
s^2 + 0.5 s + 1
From input 2 to output:
1
-----
s + 1
From input 3 to output:
1
-------------------
0.7 s^2 + 0.5 s + 1
Continuous-time transfer function.
Now with the ss function, the 1x3 transfer function is converted to the correspondig state space representation of the system:
>> sys = ss(sys)
sys =
A =
x1 x2x3x4x5
x1 -0.5-1000
x2 10000
x3 00-100
x4 000-0.7143-1.429
x5 00010
B =
u1 u2u3
x1 100
x2 000
x3 010
x4 001
x5 000
C =
x1 x2x3x4x5
y1 01101.429
D =
u1 u2u3
y1 000
Continuous-time state-space model.
The code you posted in your question just combines both steps in one line of code.
Best Answer