You are on page 1of 14

Digital Signal Processing

Lecture 5
Convolution Sum

1
Analysis of Discrete Time Linear Time
Invariant Systems

There are two basic methods for analyzing


the behavior or response of a linear
system to a given input signal.
• Method based on direct input-output
equation of a system.
• Decomposition of the input signal into a
sum of elementary signals (usually
impulses).

2
Impulse Response
• The impulse response is the output of a LTI system due to
an impulse input applied at time t = 0 or n = 0.
• The impulse response completely characterizes the behavior
of any LTI system.
• If the input to a linear system is expressed as a weighted
superposition of time-shifted impulses, then the output is
the weighted superposition of the response to each time
shifted impulse.
• If the system is also time invariant, then the system response
to a time shifted impulse is a time shifted version of the
system response to an impulse.
• Thus the output of a LTI system is a weighted superposition
of time shifted impulse responses. This weighted
superposition is termed as the Convolution Sum for discrete
time systems and Convolution integral for continuous time
3
systems.
The Convolution Sum
Consider the product of a signal x[n] and the impulse
sequence [n], written as
x[n][n] = x[0][n]
Generalize this relationship to the product of x[n] and
a time shifted impulse sequence to obtain
x[n][n-k] = x[k][n-k]
This property allows us to express x[n] as the
following weighted sum of time shifted impulses:
x[n] = ….. + x[-2][n+2] +x[-1]n+1]+x[0][n]+
x[1][n-1]+x[2][n-2]+….

x[n ]   x[k ] n  k  (1)
k  
4
The Convolution Sum (cont.)
Let the operator H denote the system to which the
input x[n] is applied. Thus using (1) to represent
the input x[n] to the system results in the output
  
y[n]  H   x[k ][n  k ]
k   

Using the linearity property, we write



y[n]   x[k ]H  n  k 
k  
(2)
or

y[n]   x[k ]h[n  k ]
k  
(3)

5
where h[n-k] = H{[n-k]}.
The sum in (3) is termed the Convolution Sum and
is denoted by the symbol *, that is,

(4)

6
Steps to compute Convolution Sum
1- Folding: fold h[k] about k=0, to obtain h[-k].

2- Shifting: shift h[-k] by n samples to obtain h[n-k].

3-Multiplication: multiply x[k] by h[n-k] to obtain


product sequence x[k]h[n-k].

4- Summation: sum all the values of the product sequence


to obtain value of output at time n.
• The formula that gives the response y(n) of LTI system
as a function of the input signal x[n] and the unit
sample response h[n] is called convolution sum.
This sum of products is in fact a function of n that
represents the overlap between x[n] and the time-reversed
and shifted version of h[n] 7
Convolution Sum
• Example 1:
The impulse response of a linear time invariant
system is h[n] = {1, 2, 1, -1}

Determine the response of the system to the input


signal x[n] = {1, 2, 3, 1}

Solution: The first step in the computation of


convolution is to fold h[k]. Complete solution is
given in the next slide.

8
-1 1 2 1
-1 1 2 1
h[-k] -1 1 2 1
x[n] 0 1 2 3 1
-1 1 2 1
-1 1 2 1
-1 1 2 1
-1 1 2 -1
1

x[n]*h[n] = [0, 1, 4, 8, 8, 3, -2, -1] 9


Example 2: Assume that an LTI system has impulse
response
h[n] = {1 2 1}

Determine the output of this system in response to the input


x[n] = {2 3 -2}
x[n]*h[n] = {0, 2, 7, 6, -1, -2}
Solution:
1 2 1
1 2 1
h[-k] 1 2 1
x[k] 0 2 3 -2
1 2 1
1 2 1
1 2 1 10
Example 3: Determine the output y[n] of a linear
time invariant system with impulse response h[n] =
anu[n], |a| < 1, when the input is a unit step
sequence, that is x[n] = u[n].
Solution:
 

 x[k ]h n  k    a u[ n  k ]
nk
x[n] * h[n] 
k   k 0

 
a n
 (a)
k 0
k
 a n  (1 / a ) k
k 0

n n 1
 a [1  1 / a  1 / a  ] 
n 2 a a

1 1/ a a 1
11
Example 4:
Determine the impulse response for the cascade of
two linear time-invariant systems having
impulse responses h1[n]=(1/2)nu[n] and h2[n] =
(1/4)nu[n].
Solution: k n k

1 n
1
   
h1 n * h 2 n   h1 [k ]h 2 [n  k ]      
k 0 k 0  2   4 

 
n n n
1 k 1
   2    1  2  2 2  ......
4 k 0 4
1
n
 2 n 1  1   1  n   1 
n
    2    
4  2  1   2    2  
   12
Example H.W
Find the convolution of the two sequences x[n] and
h[n] given by,
1- x[n] = [3 1 2] h[n] = [3 2 1]

2- x[n] = [1 2 4] h[n] = [1 1 1 1 1]

3- x[n] = {0 1 -2 3 -4} h[n] = [0.5 1 2 1 0.5]

4- x[n] = [1, 1, 0, 1, 1], h[n] = [1, -2, -3, 4]

5- x[n] = (1/2)nu[n], h[n] = (1/4)nu[n]


13
Properties of Convolution
• Commutative Law
x[n]*h[n] = h[n]*x[n]
• Associative Law
[x[n]*h1[n]]*h2[n] = x[n]*[h1[n]*h2[n]]
• Distributive Law
x[n]*[h1[n] + h2[n]] = x[n]*h1[n] + x[n]*h2[n]

14

You might also like