Professional Documents
Culture Documents
1
To perform partial fraction expansion on T (z)
4z + 1
T (z) =
z2 −z−2
we enter the following Matlab commands.
r =
3
1
p =
2
-1
k =
[]
2
The residue command also works when some poles are complex. For exam-
ple, to find the partial fraction expansion of X(z)
4z + 3
X(z) =
2 z 3 − 3.4 z 2 + 1.98 z − 0.406
we can use the following Matlab commands.
r =
36.2500
-18.1250 +13.1250i
-18.1250 -13.1250i
p =
0.7000
0.5000 + 0.2000i
0.5000 - 0.2000i
k =
[]
3
Here is an example with a repeated pole. To perform partial fraction expan-
sion on T (z)
2z + 1
T (z) =
z 3 + 5z 2 + 8z + 4
we enter the following Matlab commands.
r =
1.0000
3.0000
-1.0000
p =
-2.0000
-2.0000
-1.0000
k =
[]
4
The residue command also works in the other direction. To write G(z),
5 6 7
G(z) = + −
z − 3 z + 4 z + 1/5
>> r = [5 6 -7];
>> p = [3 -4 -1/5];
>> [num,den] = residue(r,p,[])
num =
den =
The argument k is needed only when the degree of the numerator is greater
than or equal to the degree of the denominator, so it was not needed for these
examples.
5
In this example, the degree of the numerator is greater than the degree of
the denominator, so k is required.
r =
1.0000
4.0000
-3.0000
p =
0.8000
-0.3000
0.2000
k =
3.0000 1.0000