Experiment No.
4
Z-TRANSFORM AND INVERSE Z-TRANSFORM
OBJECTIVE
To manipulate the Z-transform and Inverse Z-transform practically using MATLAB.
EQUIPMENT
Computer System & MATLAB software Installed on it
THEORY
As the Fourier transform forms the basis of signal analysis, the z-transform forms the basis of
system analysis. If x[n] is a discrete signal, its z-transform X(z) is given by:
The z-transform maps a signal in the time domain to a power series in the complex
(Frequency) domain: x[n] → X(z).
There are many advantages to working with z-transformed signals:
Linearity and superposition are preserved
x[n − k] → z−kX(z)
x[− n] → X(1/z)
anx[n] → X(z/a)
x[n] ∗ y[n] → X(z)Y (z)
The overall result is that the algebra of system analysis becomes greatly simplified in the z domain.
The only tradeoff is the necessity of taking an inverse transform to obtain time domain responses.
Since the response y[n] of an LTI system to input x[n] is given by the convolution x[n] ∗ h[n],
where h[n] is the impulse response, we have
The ratio H(z) = Y (z)/X(z) defines the impulse response (and so the system response), and is
called the transfer function of the system
PROCEDURE
Polynomials and Partial Fraction Expansion
Partial fraction expansion of polynomials and roots of the polynomials are important while
determining the z-transform and its inverse. MATLAB provides with the following functions:
a) residue
b) poly
See help for these functions in MATLAB and do the following example.
b = 1;
a = poly ([0.8, 0.8, -0.8])
[r,p,k] = residuez(b,a)
[b,a] = residuez(r,p,k)
The first call to residue with 2 arguments performs partial fraction expansion of the polynomial
given by x and y. The second call with 3 arguments reverses the operation. The following
example shows how to calculate magnitude and phases of the complex roots.
b = [1,0.4*sqrt(2)]
a=[1,-0.8*sqrt(2),0.64]
[R,p,C] = residuez(b,a)
Mp=abs(p') % pole magnitudes
Ap=angle(p')/pi % pole angles in pi units
Z-Transform and MATLAB
MATLAB can take z-transform of a polynomial for you. For this you need to define the
Independent variable ‘n’ as a symbol in MA TLAB. See help for ‘syms’ for defining symbols.
TASKS:
1. What is the MATLAB code of z- transform of the function 0.5^n?
2. What is the MATLAB code of z- transform of the sin(n) function?
3. Compute the inverse Z-transform of 2*z/(z-2)^2. By default, the inverse transform is in
terms of n.
4. Find z- transform of
i) n^2
ii) n*a^2
iii) a^n
iv) n*((0.5)^n)*cos(pi*n/3))
5. Find the z-transform of the given function.
6. Find the inverse z-transform of the given function.
7. Find the first five term of the inverse z-transform of
8. Find the partial fraction expansion of the following z-Transform.
9. Find the z-transform of given function X(z) with partial fraction expression.
Solution:
1. What is the MATLAB code of z- transform of the function 0.5^n?
2. What is the MATLAB code of z- transform of the sin(n) function?
3. Compute the inverse Z-transform of 2*z/(z-2)^2. By default, the
inverse transform is in terms of n.
4. Find z- transform of
i) n^2
ii) n*a^2
iii) a^n
iv) n*((0.5)^n)*cos(pi*n/3))
5. Find the z-transform of the given function.
6. Find the inverse z-transform of the given function.
7. Find the first five term of the inverse z-transform of
8. Find the partial fraction expansion of the following z-Transform.
9. Find the z-transform of given function X(z) with partial fraction
expression.
PLO
no Criteria Beginning (1) Developing (2) Accomplished (3) Exemplary (4)
Apply Student is unable to apply With instructor/ supervisor’s With instructor/ Student is able to apply all
Procedural described procedure to guidance, student is able to supervisor’s guidance, procedural knowledge to
5 Knowledge to perform activity despite apply some of the described student is able to apply all independently perform
perform an instructor/ supervisor’s procedure to partially described procedure to activity without instructor/
activity guidance. perform activity. fully perform activity. supervisor’s guidance.
Student is able to
Effectively
Student is unable to Student is able to partially Student is able to effectively and
document/
effectively document/ document/ communicate effectively document/ independently document/
10 communicate
communicate performed performed activities despite communicate performed communicate performed
performed
activities despite guidance. guidance. activities with guidance. activities form without any
activities
guidance.
Psychomotor Domain Rubrics
Activity Name EXPERIMENT No. 4
Group No.
Student Roll No.
N C PL Domain +
o L O Taxonomy Criteria Awarded Score (out of 4 for each cell)
. O
Apply Procedural Knowledge to perform an
1 4 1 P3
activity
2 5 10 A3 Effectively reported the activity performed in lab