You are on page 1of 23

Analysis of DT Systems

We can solve for the output y(n) by analyzing the effect


ECE 411 of the system h(n) on the input signal x(n).
Methods of analysis:
Signals, Spectra, and Convolution
Signal Processing Correlation
Difference Equations
Discrete-Time Linear Time-Invariant
(DT-LTI) Systems

2 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems

We can define the output of a system as

y(n) F[y(n1), y(n2),..., y(n N), x(n), x(n1), x(n2),...,x(n M)]


Analysis of DT-LTI Systems
Where F[ ] denotes some functions inside the brackets.
Simplifying,

N M The Convolution Sum and Correlation


y(n) ak y(nk) bk x(nk) Where ak and bk are
k1 k0 coefficients independent
of x(n) and y(n)

3 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems

1
Convolution
It is possible to determine the current value of a Where the convolution sum involves four operations:
signal x(n) by getting its value at k. 1. Folding fold h(k) about 0 to obtain h(k).
By multiplying the value of x(n) at k by a function h, 2. Shifting shift h(k) to the right (left) if n is positive
we can get the effect of x(n) on h. (negative) to obtain h(n k).
3. Multiplication multiply x(k) by h(n k) to obtain the
Therefore
product sequence.
4. Summation sum all the product sequences to obtain
y ( n) x ( k ) h( n k )
k
the value of the output at time n = n0.

5 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems 6 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems

Example Exercise
The impulse response of an LTI system is

h(n) [ -1, 1 , 2 , 1 ] Given: h(n) [ -1, 1 , 2 ]



with the input signal being x(n) [ 1, 0 , 1 ]
x(n) [ 1, 2 , -1, 2 ]
Answer: y (n) [ -1, 1, 1, 1, 2 ]
Determine the output y(n).

Answer: y (n) [ - 1, - 1, 5 , 2, 2, 3, 2 ]

7 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems 8 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems

2
Properties of the Convolution Sum Example
We express the convolution sum as Find the response of the system y(n) given:
x(n) [2 1 0 4 3 2] h2 (n) [1 0 3 2 1]
y (n) x ( k ) h ( n k ) x ( n) h( n)
k

h1(n) [3 2 2 1 1 5] h3(n) [1 1 2 0 1]

Commutative Law
x ( n) h( n) h( n) x ( n ) x(n) H1
Associative Law + y(n)
x(n) [h1 (n) h2 (n)] [ x(n) h1 (n)] h2 (n) H2 H3
Distributive Law
x(n) [h1 (n) h2 (n)] [ x(n) h1 (n)] [ x(n) h2 (n)] Answer: y(n) [4 4 9 15 22 18 5 39 3 37 11 12 1 2]

9 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems 10 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems

>> h3=[-1 1 2 0 1]; >> h=h1+h23


>> h2=[0 1 0 3 2 -1]; h =
>> h23=conv(h2,h3) Columns 1 through 10
h23 = 0 2 3 -3 2 9 8 1 2 -1
Columns 1 through 10 Column 11
0 -1 1 -1 1 10 3 1 2 -1 0
Column 11 >> y=conv([2 -1 0 4 -3 -2],h)
0 y =
>> h1=[0 3 2 -2 1 -1 5 0 0 0 0] Columns 1 through 10
h1 = 0 4 4 -9 15 22 -18 5 39 -3
Columns 1 through 10 MATLAB Columns 11 through 16
0 3 2 -2 1 -1 5 0 0 0 -37 -11 -12 -1 2 0
Column 11 >>
0
>> clc

3
Impulse Response, h(n) Causal DT-LTI System
The response (output) of an arbitrary system H from a A DT-LTI system is causal if and only if its impulse
unit impulse signal. response h(n) is zero for negative values of n.


x(n) = (n) H y(n) = h(n) y ( n) x ( k ) h( n k ) h ( k ) x ( n k )
k 0 k 0

13 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems 14 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems

Stability of a DT-LTI System Finite Impulse Response (FIR) System


An LTI system is stable only if its impulse response A system with a finite-duration impulse response.
h(n) is absolutely summable.
M 1
y ( n) h( k ) x ( n k )
k 0

| h( k ) |
k M
h(n) = 0
H
n n
0 0 M1

x(n) = (n) y(n) = h(n)

15 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems 16 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems

4
Infinite Impulse Response (IIR) System FIR Systems vs. IIR Systems
A system with an infinite-duration impulse response. An FIR system has a finite duration impulse response,
while an IIR has an infinite impulse response. Thus an

FIR system has zero output outside some finite
y ( n) h( k ) x ( n k )
k 0 interval.
Using convolution, we can see the output of a system
at any given time n is simply a weighted combination of
H the input samples x(n), x(n 1), , x(n M + 1).
n n
0 0
It weighs them by the values of the impulse response
x(n) = (n) y(n) = h(n) h(k) at k = 0, 1, 2,, M + 1.

17 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems 18 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems

Correlation
In effect, the system acts as a window that views only Correlation computes for the degree to which two
the most recent M input signals forming the output. It signals are similar (related) and extract some of the
neglects, or simply forgets all prior input samples. information depending on the application.
Therefore it has a finite memory length of M. Often used in sonar, radar, digital communications,
In contrast, for an IIR system, it has infinite duration geology, etc.
impulse response, requiring infinite memory.

19 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems 20 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems

5
A Correlation Example
Let x(n) be the Having the reference signal x(n), and the received signal
transmitted signal and y(n), the problem is to compare y(n) with x(n) to
REC
EIV
ED y(n) the received signal. If determine if there is a target, and if so, determine the
a target is present in time delay D to compute for the distance.
NS MIT
TED space, y(n) will consist of In practice, x(n D) is heavily corrupted by noise to the
TRA

a delayed version of x(n) point where visual inspection of y(n) does not reveal
(due to the round-trip any information.
y (n) x(n D) w(n) time) from the reflection, Correlation provides us with a means of extracting this
where: corrupted by noise. important information from y(n).
- attenuation due to free space
D round-trip delay If there is no target, y(n)
w(n) additive noise will consist of noise
alone.
21 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems 22 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems

Transmitted Signal
2
Correlated Signal
1.5 10

0.5

0 5
0 10 20 30 40 50 60 70 80 90 100 Actual Delay

Ideal Received Signal


2
0
1.5

1
Delay
0.5 (Round-trip time)

0 -5
0 10 20 30 40 50 60 70 80 90 100

Estimated start of received signal

Received Signal with Attenuation and Noise

1 -10

-1
-15
0 10 20 30 40 50 60 70 80 90 100
0 10 20 30 40 50 60 70 80 90 100

23 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems 24 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems

6
Cross-correlation
Suppose we have two real signals, x(n) and y(n), each Comparing the two, we have
having finite energy. The cross-correlation of x(n) and
y(n) is a sequence rxy(l) defined as rxy (l ) ryx (l )

Therefore, rxy(l) is simply the folded version of ryx(l),
rxy (l ) x(n) y (n l ) or rxy (l )
n
x(n l ) y (n)
n where folding is done with respect to l = 0. Hence rxy(l)
Where l is the time shift (lag), and the subscripts xy provides exactly the same information as ryx(l) with
indicate the sequences being correlated. The order of respect to the similarity of x(n) to y(n).
the indices indicate the direction in which one sequence A special case of correlation is autocorrelation where
is shifted relative to the other. y(n) = x(n).

x (n) x (n l ) x (n l ) x(n)

rxx (l )
ryx (l ) y (n) x(n l )
n
or ryx (l ) y (n l ) x(n)
n n n

25 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems 26 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems

Autocorrelation Example:
Example Yearly Wlfer Sunspot Numbers
x(n) [1 0 1 1 2] y(n) [1 0 1 1 3]
Yearly Wolfer Sunspot Numbers
Given: 200

150

1. Determine the cross-correlation sequence rxy(l). 100

What is the point of maximum relation?


50

2. Solve for ryx(l) and compare it with rxy(l).


0
1770 1780 1790 1800 1810 1820 1830 1840 1850 1860 1870

Answers: 1. rxy(l) [3 1 4 4 7 3 1 1 2]
Autocorrelation Sequence
1

The point maximum relation is at l = 2


0.5

2. ryx(l) [2 1 1 3 7 4 4 1 3]

0
We can see that ryx(l) is the folded version
1 Solar Cycle
of rxy(l), therefore ryx(l) = rxy(l). -0.5
0 5 10 15 20 25
27 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems 28 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems

7
Example Observations
Determine the autocorrelation sequence of x(n): 1. The convolution of two sequences is computed by Folding,
Shifting, Multiplication and Summation.
2. The crosscorrelation of two sequences is computed by Shifting,
x(n) [1 0 1 1 2] Multiplication and Summation.
3. From (1) and (2), it follows that rxy(l) = x(l)*y(l). The
Answer: rxx(l) [2 1 3 3 7 3 3 1 2]
convolution of x(n) and y(n) is the crosscorrelation of the two
sequences.
We can see that rxx(l) attains its maximum
value at l = 0. Also, the autocorrelation 4. If rxy(l) = ryx(l), thus rxy(l) is the folded version of ryx(l)
sequence is an even function. 5. From (4), it follows that the autocorrelation function is an even
function.
6. If y(n) = h(n)*x(n), therefore ryx(l) = h(l)*rxx(l).
7. Since ryy(l) = ry(l)*ry(l), therefore ryy(l) = rhh(l)*rxx(l).

29 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems 30 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems

DT Systems Described by Difference Equations

We have seen that it would be impossible to implement


an IIR system using convolution. Fortunately, there is a
way to realize this by conveniently describing a system
Analysis of DT-LTI Systems by difference equations.

Systems Described by Constant-


Coefficient Difference Equations

32 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems

8
Recursive DT System Non-recursive DT System
A system whose output y(n) at any given time n A system whose output y(n) at any given time n
depends on any number of past output values y(n 1), depends only the present and past inputs.
y(n 2),, y(n N).

y(n) = F[y(n 1), y(n 2),, y(n N), x(n)] y(n) = F[x(n), x(n 1),, x(n M)]

x(n) + y(n) x(n) + y(n)

z 1 z 1

33 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems 34 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems

General Form of an Nth-order Difference Equation of a


DT-LTI Recursive System
Linearity
The system is linear if it satisfies the following:
The total response is equal to the sum of zero-state and
zero-input response.
N M
y(n) ak y(n k ) bk x(n k ) The system is zero-state linear
k 1 k 0 The system is zero-input linear

where: y(n) = output response


y(n k) = previous outputs
x(n k) = input response
ak, bk = coefficients

35 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems 36 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems

9
Time Invariance Stability
The system described by the general form of Nth order Recursive system described by constant-coefficient
difference equation is time invariant if the coefficients difference equation is BIBO stable if and only if for
ak and bk are constants for all k. every bounded input and every bounded initial condition,
the total system response is bounded.

The recursive system described by a linear constant-


coefficient difference equation is therefore linear, time
invariant and BIBO stable.

37 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems 38 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems

Zero-State Response, yzs(n) Zero-Input Response, yzi(n)


Also known as a forced response. Also known as natural or free response.
Response of a relaxed system (zero initial conditions) Response of a non-relaxed system (non-zero initial
on a given input signal, x(n). conditions) given that the input signal is set to zero.
Response of the system by convolving the input and Response due to the memory of the system.
the impulse response of the system.

39 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems 40 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems

10
Total Response
The total response of the system is the sum of the
zero-state and the zero-input response.

Analysis of DT-LTI Systems


yt(n) = yzs(n) + yzi(n)

Solution of a Linear Constant Coefficient


Difference Equations

41 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems

Homogeneity Order of a Difference Equation


A homogeneous system is one where the input including The order of a DT system described by a difference
all constants, is zero. Otherwise the system is equation is the difference between the highest
inhomogeneous. argument (k) of the output (dependent variable) y(n)
Simply put, a homogeneous system defined by a and the lowest.
difference equation is one composed entirely of output
functions (all terms are of y(n)), with the input
functions x(n) including constants are zero.

43 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems 44 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems

11
Solution of Linear Constant Coefficient
Difference Equations
Iterative Method
There are at least three methods of solving LCCDEs by The iterative method is the simplest but most tedious.
the direct method: To get the value of the output at a given time n, the
Iterative or recursive DE is evaluated for different values of n, given some
Classical or mathematical initial condition.
Systems-oriented approach The number of initial conditions required to solve for
Indirect method refers to the application of the the output value depends on the order of the DE, i.e. a
Z-transform in solving DEs. 1st order DE requires 1 initial condition, a 2nd order DE
needs 2 initial conditions, and so on.

45 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems 46 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems

Example 1 Example 2
Determine y(1), y(2), and y(3) for an initially relaxed Determine y(4) for a DT system characterized by the
system defined by LCCDE

y(n) y(n 1) = x(n) 2y(n) y(n 1) + y(n 2) = x(n)


where: x(n) = nu(n) where: x(n) = n2u(n)
y(0) = 1
y(1) = 3
Answer: y(1) = 1
y(2) = 3
y(3) = 6 Answer: y(4) = 43/4

47 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems 48 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems

12
Classical Method or Mathematical Homogenous Solution, yh(n)
The total response of a system described by linear The homogeneous solution is obtained by making the
constant-coefficient difference equation (LCCDE) is the input function equal to zero.
sum of two parts, homogeneous and particular solution, N N
i.e. y ( n) a k y ( n k ) or a
k 0
k y (n k ) 0
k 1

y(n) = yh(n) + yp(n) Assume a solution in the form


yh (n) Cn

49 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems 50 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems

Example 1
Case 1: Distinct Roots Determine yh(n) for the DE
The general form is

yh (n) C11 C2 2 ..... C N N


n n n
y(n) y(n 1) 2y(n 2) = x(n)
Case 2: Repeated Roots
The general form is
yh (n) C1n C2 nn .C3 n 2 n .... Cm n m1n
Answer: yh(n) = C1(2)n + C2(1)n
* Since the input is set to zero, x(n) = 0, the homogeneous
solution can be used to obtain the zero-input response, yzi(n).

51 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems 52 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems

13
Example 2 Example 3
Determine yh(n) for the DE Determine yzi(n) for the DE

y(n) y(n 1) + 2y(n 2) = x(n) 6y(n) + y(n 1) 2y(n 2) = x(n)

given the initial conditions:


y(2) = 0 and y(1) = 1.
Answer: yh (n) C1 12 2
7

j C2 1
2 2
7
j
2 C e
n
1
j 0.385 n
C2 e j 0.385 n Answer: yzi (n)
8 2 3 1

n n

21 3 14 2

53 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems 54 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems

Particular Solution, yp(n) General Form of the Particular Solution

Assume that the particular solution yp(n) will depend Input Signal, x(n) Particular Solution, yp(n)

on the form of the input x(n), that is if x(n) is (n) (x(n)= 0; n > 0) 0
exponential, the particular solution is also exponential A (constant) K
or if x(n) is sinusoid then yp(n) would also be a sinusoid. AMn KMn
The particular solution is any solution satisfying AnM K0nM + K1nM 1 ++ KM

AnnM An(K0nM + K1nM 1 ++ KM)


N M

a
k 0
k y p (n k ) bk x(n k )
k 0
, a0 = 1 Acos0n
K1 cos0n + K2 sin0n
Asin0n

* The zero-state response yzs(n) can be obtained by using the total


solution y(n) = yh(n) + yp(n) and assuming that all initial conditions
are zero y(1), y(2), y(3) = 0.
55 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems 56 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems

14
Example
To determine yp(n), use the following procedure: Given y(n) + 2y(n 1) = x(n)
1. Postulate a trial solution where: x(n) = 2u(n) + 4nu(n)
The assumed yp(n) must not appear in yh(n) to avoid
redundancy. Select a particular solution that is linearly
y(1) = 1
independent of the terms in the homogeneous solution.
One method to avoid a trial solution with a redundant term solve for y(2) and check using iterative.
is by treating it similarly to a characteristic equation with
multiple roots.
2. Substitute a trial solution into the LCCDE
Answer:
1 n 2

yt (n) 2 1 4n u(n)
3. Evaluate the coefficients K 3 3
In evaluating the equation, none of the terms must vanish. y(2) = 10
4. Determine the final solution

57 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems 58 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems

Systems-Oriented Approach Systems-Oriented Approach on the Last Example

Recall that the total response of a system is the sum Given y(n) + 2y(n 1) = x(n)
of the zero-input and zero-state responses where: x(n) = 2u(n) + 4nu(n)
yt(n) = yzi(n) + yzs(n) y(1) = 1

In many cases it is useful to determine the natural and


forced responses (yzi(n) and yzs(n)) of the system. yzi (n) 2 2
n
Answer:

Input signal Forced response, yzs(n) Total response


5
3
2
3
2
yzs (n) (2)n u(n) 4n u(n)
3

x(n) H Natural response, yzs(n) yt(n)

Prior excitation or initial condition


yt (n)
1
3 3

2n 2 1 4n u(n)
(from systems memory), I.C. or y(n)

59 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems 60 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems

15
Impulse Response of DT-LTI Recursive System

Impulse Response the response of an LTI relaxed


system to a unit sample excitation, (n).
The impulse response of an initially relaxed LTI Recursive
System is equal to the zero-state response yzs(n) for
Analysis of DT-LTI Systems
the input x(n) = (n).
n
Mathematically: y zs (n) h(k ) x(n k )
k 0 Realization of DT-LTI Systems
if x(n) = (n)
n
y zs (n) h(k ) (n k ) h(n) (n n)
k 0

y zs (n) h(n)
61 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems

Structures for the Realization of DT Systems Direct Form I Structure


Consider the system described by the LCCDE
b0 v(n)
x(n) + + y(n)
y(n) = a1y(n 1) + b0x(n) + b1x(n 1)
z-1 z-1
b1 -a1

The system uses separate delays for the input and S1 S2


output samples and is called a Direct Form I structure.
The system can also be viewed as two systems in
cascade. The first is a non-recursive system
v(n) b0 x(n) b1 x(n 1)
The second is recursive system described by
y (n) a1 y (n 1) v(n)
63 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems 64 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems

16
Direct Form II Structure

w(n) b0 w(n) b0
x(n) + + y(n) x(n) + + y(n)

z-1 z-1 z-1


-a1 b1 -a1 b1

S2 S1 S2 S1
However, as seen previously, interchanging the order Combining the two delays into a single delay unit
of the two systems will not affect the output. gives us the Direct Form II structure.
h1 (n) h2 (n) h2 (n) h1 (n)
We can see that the delays in the middle are
redundant.
65 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems 66 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems

An improved realization of DT-LTI systems where only Observations:


one group of delay (memory) elements is used. Both structures have the same number of multiplications
The Direct Form II structure is the cascade of (M + N + 1 multiplications)
Direct Form I has M + N delay (memory) elements.
N Direct Form II has M or N delay elements (whichever is
w(n) ak w(n k ) x(n) higher)
k 1

M
y (n) b
k 0
k w(n k )

67 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems 68 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems

17
An FIR System An IIR System
A system whose response to a unit sample is a finite A system whose response to a unit sample is an
duration signal. infinite duration signal.
Also known as a moving average system. Always in the form of a recursive system.
Usually in the form of a non-recursive system. The general form of an IIR system is:
The general form of an FIR system is:
N

M y (n) a k y ( n k ) b0 x ( n )
y (n) b
k 0
k x(n k ) k 1

69 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems 70 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems

Second-order Systems Example


An LTI system described by an LCCDE with an order Determine the first 15 values of the unit step response of
of 2 (N = 2). the system defined by LCCDE
The basic building block in analyzing higher-ordered
systems. y(n) = 1.0368y(n 1) 0.437y(n 2) + 0.114x(n) + 0.1498x(n 1) + 0.114x(n 2)

Draw its Direct Form I implementation and compare the


response with the Direct Form II implementation.

71 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems 72 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems

18
>> simulink >> simulink
>> >>

Click on New to bring up this window

>> simulink >> simulink


>> >> From Math Operations
blockset

From Discrete blockset

19
>> simulink >> simulink From Sinks blockset
>> >>

From Sources blockset

For 15 samples in For the output y(n) to


10 sec (including n = 0) be a matrix array

>> simulink >> simulink


>> >>

Save the file and click on Run

- Press Ctrl+E to bring up the simulation configuration screen.


- Use discrete for the solver

20
>> simulink >> simulink
>> y View the output >> y
y = y =
0.114000000000000 0.114000000000000
0.381995200000000 0.381995200000000
0.724046023360000 0.724046023360000
0.961597214139648 0.961597214139648
1.058448284014003 1.058448284014003
1.055077358008106 1.055077358008106 Redo for Direct Form II
1.009268149497086 1.009268149497086
0.963245919684837 0.963245919684837
0.935544115013962 0.935544115013962
0.926929996136171 0.926929996136171
0.930101796144381 0.930101796144381
0.937153826930602 0.937153826930602
0.943079613026168 0.943079613026168
0.946142435799550 0.946142435799550
0.946728994505841 0.946728994505841
>> >>

0.946728994505841 0.946728994505841
>> [y y1] Compare the output of DF I (y) with the output of DF II (y1) >> [y y1]
ans = ans =
0.114000000000000 0.114000000000000 0.114000000000000 0.114000000000000
0.381995200000000 0.381995200000000 0.381995200000000 0.381995200000000
0.724046023360000 0.724046023360000 0.724046023360000 0.724046023360000
0.961597214139648 0.961597214139648 0.961597214139648 0.961597214139648
1.058448284014003 1.058448284014003 1.058448284014003 1.058448284014003
1.055077358008106 1.055077358008106 1.055077358008106 1.055077358008106
1.009268149497086 1.009268149497086 1.009268149497086 1.009268149497086
0.963245919684837 0.963245919684837 0.963245919684837 0.963245919684837
0.935544115013962 0.935544115013962 0.935544115013962 0.935544115013962
0.926929996136171 0.926929996136171 0.926929996136171 0.926929996136171
0.930101796144381 0.930101796144381 0.930101796144381 0.930101796144381
0.937153826930602 0.937153826930602 0.937153826930602 0.937153826930602
0.943079613026168 0.943079613026168 0.943079613026168 0.943079613026168
0.946142435799550 0.946142435799550 0.946142435799550 0.946142435799550
0.946728994505841 0.946728994505841 0.946728994505841 0.946728994505841
>> subplot(2,1,1);stem(0:14,y);subplot(2,1,2);stem(0:14,y1) >> subplot(2,1,1);stem(0:14,y);subplot(2,1,2);stem(0:14,y1)
>> Compare the outputs graphically >>

21
1. Find the response of the system y(n) given:
h1(n) [2 1 0 1 3 4]

h2 (n) [2 0 3 5 2]
ECE 411 h3(n) [1 0 2 3 1]

Signals, Spectra, and To the input x(n) [2 1 0 4 3 2]


Signal Processing
x(n) H1
+ H3 y(n)
Problem Set (DT-LTI Systems)
H2

Answer: y(n) [4 8 5 4 16 24 41 20 43 61 48 144 26 38 12]


86 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems

2. Given 4y(n) 4y(n 1) + y(n 2) = ()nu(n) 3. Given y(n) 2y(n 1) + 2y(n 2) = x(n)
where: y(2) = 1 where: I.C. = 0, x(n) = (n)
y(1) = 1
find yt(n).
find yt(n).

Answer:
31 9 1
n
1
y(n) n n 2
n n 3

u ( n) Answer: y(n) 2 n 1
cos (n 1)
22 8 2 2 4

87 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems 88 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems

22
4. Solve problem #2 using the systems-based approach
ASSIGNMENT 3:
4y(n) 4y(n 1) + y(n 2) = ()nu(n)
where: y(2) = 1 Answer the following problems at the end of Chapter 2
y(1) = 1 on the textbook (Digital Signal Processing,
Proakis/Manolakis, 3e).
Problems 2.16 2.18, 2.25 2.28, 2.30, 2.43, 2.47
yzi (n) 54 12 34 n 12
n n
Answer: Use an A4-sized paper

yzs (n) 14 12 83 n 12 n 2 12 u(n)


n n n 3 Handwritten (including the problem)
Submission is on our next meeting
yt (n) 32 12 89 n 12 n 2 12 u(n)
n n n 3

89 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems 90 ECE 411 - Signals, Spectra, and Signal Processing: DT-LTI Systems

23

You might also like