Let's say that I have this transfer function.
$$G (s) = \frac {s^4 + 4s^3 + 7s^2 + 10s + 8}{s^5 + 6s^4 + 15s^3 + 25s^2 + 32s + 20}$$
And with MATLAB function minreal, I can get this transfer function
$$G_{min} (s) = \frac {s^3 + 2s^2 + 3s + 4}{s^4 + 4s^3 + 7s^2 + 11s +10}$$
If I have the numerators and denomerators from $G (s) $ in two vectors $num, den $. Which MATLAB command should I use to cansle out poles against zeros so I can get the minimal realization?
I have the poles and zeros in two separate vectors. How can I (easy) use MATLAB 's smart functions to check if I have equation zeros and poles and I have, remove them.
Here is the answer:
Done!