Docsity

ECE 6364 Spring 2009 Homework 9: Convolution and DFT - Prof. Thomas Hebert, Assignments of Digital Signal Processing

Toggle sidebar
bg1
ECE 6364 Spring 2009 HW 9 Due 4/13
Problem 1.
Jain – Problem 5.7
Problem 1.
Find the periodic convolution of X and Y. Note that this is the same result that would be obtained by computing
IDFT{ DFT{ X } x DFT{ Y } } where x denotes element-by-element multiplication.
X =
[]
⎥
⎦
⎤
⎢
⎣
⎡
113
012 Y =
[]
⎥
⎦
⎤
⎢
⎣
⎡
431
210
Problem 2.
You want to do linear convolution of a 256x256 image f(i,j) with a 9x9 mask m(i,j) to form a 264x264 linear
convolution c(i,j) image. Using image-indexing, you number the (0,0)th pixel of the image f( , ) as the upper-left-
hand-corner of f( , ), so that the pixels of the image are numbered f(0,0) to f(255,255). Using image-indexing, you
number the (0,0)th pixel of the mask m( , ) as the pixel directly in the middle of the 9x9 pixel mask, so that the
pixels of the mask are numbered m(-4,-4) to m(4,4).
The 264x264 linear convolution image is therefore correctly numbered c(-2,-2) to c(262,262).
To implement linear convolution you are to use DFTs with zero-padding. You load the image f( , ) and mask m( , )
into the upper-left-hand corners of separate 264x264 pixel matrices below, and zero-padding the right-hand
columns and lower-rows of the matrix as necessary.. You take the DFT of both matrices, multiply the elements of
the two matrices together term-by-term to form a 264x264 product matrix, and finally take the inverse DFT of the
product matrix to obtain a 264x264 matrix Q with pixels numbered Q(0,0) to Q(263,263).
Which elements of this 264x264 matrix Q hold the central portion of the linear convolution; i.e. c(0,0) to
c(255,255)?
⎥
⎥
⎥
⎥
⎥
⎥
⎥
⎥
⎥
⎦
⎤
⎢
⎢
⎢
⎢
⎢
⎢
⎢
⎢
⎢
⎣
⎡
••
•••
••
••
•••••
•••
••
0000
0000
00
00
255,255255,0
1,0
0,2550,10,0
ff
f
fff
⎥
⎥
⎥
⎥
⎥
⎥
⎥
⎥
⎥
⎥
⎥
⎦
⎤
⎢
⎢
⎢
⎢
⎢
⎢
⎢
⎢
⎢
⎢
⎢
⎣
⎡
•••
••••
•
•••
•••••
•••
•••••
•••
−
−
−−−−
000
000
00
00
4,44,04,4
0,40,00,4
4,44,04,4
mmm
mmm
mmm
264x264 264x264
Problem 3.
Jain – Problem 5.24a
Problem 4.
Compute the four 2x2 basis images of the unitary Hadamard transform.

Partial preview of the text

Download ECE 6364 Spring 2009 Homework 9: Convolution and DFT - Prof. Thomas Hebert and more Assignments Digital Signal Processing in PDF only on Docsity!

ECE 6364 Spring 2009 HW 9 Due 4/13 Problem 1. Jain – Problem 5.

Problem 1. Find the periodic convolution ofIDFT{ DFT{ X } x DFT{ Y } } where x denotes element-by-element multiplication. X and Y. Note that this is the same result that would be obtained by computing

X = ⎢⎣⎡[ ] 32 11 10 ⎥⎦⎤ Y = ⎢⎣⎡[ ] 10 31 42 ⎥⎦⎤

Problem 2. You want to do linear convolution of a 256x256 image f(i,j) with a 9x9 mask m(i,j) to form a 264x264 linearconvolution c(i,j) image. Using image-indexing, you number the (0,0)th pixel of the image f( , ) as the upper-left-hand-corner of f( , ), so that the pixels of the image are numbered f(0,0) to f(255,255). Using image-indexing, you

number the (0,0)th pixel of the mask m( , ) as the pixel directly in the middle of the 9x9 pixel mask, so that thepixels of the mask are numbered m(-4,-4) to m(4,4).The 264x264 linear convolution image is therefore correctly numbered c(-2,-2) to c(262,262).

To implement linear convolution you are to use DFTs with zero-padding. You load the image f( , ) and mask m( , )into the upper-left-hand corners of separate 264x264 pixel matrices below, and zero-padding the right-handcolumns and lower-rows of the matrix as necessary.. You take the DFT of both matrices, multiply the elements ofthe two matrices together term-by-term to form a 264x264 product matrix, and finally take the inverse DFT of the

product matrix to obtain a 264x264 matrixWhich elements of this 264x264 matrixc(255,255)? Q Q hold the central portion of the linear convolution; i.e. c(0,0) to with pixels numbered Q (0,0) to Q (263,263).

0 ,^0255 ,^1255 , 255

0 , 0 1 , 0 255 , 0 ff f

f f f ⎥⎥⎥⎥⎥

−− − − − − 00 00 0 0

4 ,^4 , 40 00 ,, 40 44 ,, 40

4 , 4 0 , 4 4 , 4 mm mm mm

m m m

Problem 3. Jain – Problem 5.24a^ 264x264^ 264x

Problem 4. Compute the four 2x2 basis images of the unitary Hadamard transform.