You are on page 1of 25

Im z

j
z=r exp(jω)
Unit circle
r
ω
Re z
-1
1 1

-j
z
z −α
z
z −α
Gain constant
assignment

factorize.m
Prog 6_1.m
6 1m
Prog 6_2.m
2 z 4 + 16 z 3 + 44 z 2 + 56 z + 32
% Program 6_1 3 z 4 + 3 z 3 − 15 z 2 + 18 z − 12
% Determination of the Factored Form Type in the numerator coefficients = [2 16 44 56 32]
% off a Rational
R ti l z-Transform
T f T
Type in
i th
the d
denominator
i t coefficients
ffi i t = [3 3 -15
15 18 -12]
12]
% Numfactors =
1.0000 4.0000 0
num = input('Type in the numerator coefficients = ');
1.0000 2.0000 0
den = input(
input('Type
Type in the denominator coefficients = ');
); 1 0000 2
1.0000 2.0000
0000 2
2.0000
0000
Denfactords=
K = num(1)/den(1); 1.0000 3.2361 0
1.0000 -1.2361 0
Numfactors = factorize(num) 1.0000 -1.0000 1.0000
Gain constant
Denfactors = factorize(den) 0.6667
0.6667(1 + 4 z −1 )(1 + 2 z −1 )(1 + 2 z −1 + 2 z −2 )
disp('Numerator
di ('N t ffactors');disp(Numfactors);
t ') di (N f t ) (1 + 3.236z −1 )(1 − 1.236z −1 )(1 − z −1 + z −2 )
disp('Denominator factors');disp(Denfactors);
disp('Gain constant');disp(K); 2

15
1.5
zplane(num,den) 1

0.5

Imaginarry Part
R1 R2 R3 R4
0

-0.5

-1

-1.5

-2

-4 -3.5 -3 -2.5 -2 -1.5 -1 -0.5 0 0.5 1


Real Part
% Program 6_2 Type in the zeros as a row vector =
% Determination
D t i ti off th
the R
Rational
ti l z-Transform
T f
[0.21 3.14 -0.3+j*0.5 -0.3-j*0.5]
% from its Poles and Zeros
% Type in the poles as a row vector = >>
format long
[-0.45 0.67 0.81+j*0.72 0.81+j*0.72]

zr = input('Type in the zeros as a row vector = '); Type in the gain constant = >> 2.2
pr = input('Type in the poles as a row vector = ');
Numerator polynomial coefficients
% Transpose
T zero andd pole
l row vectors
t 2.2 -6.05 -2.22 -1.635 0.49
z = zr';
p = pr'; Denominator polynomial coefficients
1.0 -1.84 0.19 0.458 -0.0415

k = input('Type in the gain constant = ');

[num, den] = zp2tf(z, p, k);

disp('Numerator polynomial coefficients');


disp(num);
disp('Denominator
p( polynomial
p y coefficients');
);
disp(den);

You might also like