Search code examples
matlabtransfer-function

Test if 2 transfer functions are the same in Matlab


Suppose that I have two transfer functions (or two matrices of transfer functions in the more general case). How do I test if these are the same (equal)?

>> G1 = 1/(s*(s-1));
>> G2 = 1/(s*(s-1));
>> G1 == G2 % won't work..

Solution

  • To test if two of anything are equal:

    isequal(a,b)