Compute the circular convolution x 1 (n) N ⃝ x 2 (n) for N = 4, 7, and 8.

1. Compute the circular convolution x 1 (n) N ⃝ x 2 (n) for N = 4, 7, and 8.

2. Compute the linear convolution x 1 (n) ∗ x 2 (n).

3. Using results of calculations, determine the minimum value of N necessary so that linear and circular convolutions are same on the N -point interval. 4. Without performing the actual convolutions, explain how you could have obtained the result of P5.33.3.

P5.34 Let

x(n) =

A cos (2πℓn/N ), 0 ≤ n ≤ N − 1 = A cos (2πℓn/N ) R

N (n)

elsewhere

Problems 209

where ℓ is an integer. Notice that x(n) contains exactly ℓ periods (or cycles) of the cosine waveform in N samples. This is a windowed cosine sequence containing no leakage.

1. Show that the DFT X(k) is a real sequence given by

X(k) = AN δ (k − ℓ) + AN δ (k − N + ℓ);

0 ≤ k ≤ (N − 1), 0<ℓ<N

2. Show that if ℓ = 0, then the DFT X(k) is given by

X(k) = AN δ(k);

0 ≤ k ≤ (N − 1)

3. Explain clearly how these results should be modified if ℓ < 0 or ℓ > N . 4. Verify the results of parts 1, 2, and 3 using the following sequences. Plot the real parts of

the DFT sequences using the stem function.

(a) x 1 (n) = 3 cos (0.04πn) R 200 (n) (b) x 2 (n) = 5R 50 (n) (c) x 3 (n) = [1 + 2 cos (0.5πn) + cos (πn)] R 100 (n) (d) x 4 (n) = cos (25πn/16) R 64 (n) (e) x 5 (n) = [4 cos (0.1πn) − 3 cos (1.9πn)] R 40 (n)

P5.35 Let x(n) = A cos (ω 0 n) R N (n), where ω 0 is a real number.

1. Using the properties of the DFT, show that the real and the imaginary parts of X(k) are given by

X(k) = X R (k) + jX I (k)

4 π (N −1)

5 sin [π (k − f 0 N )]

X R (k) = (A/2) cos

(k − f 0 N)

sin [π(k − f 0 N )/N ]

4 π (N −1)

5 sin [π (k − N + f 0 N )]

+ (A/2) cos

(k + f 0 N)

sin [π(k − N + f 0 N )/N ]

I (k) = − (A/2) sin (N −1)

5 sin [π (k − f 0 N )]

(k − f 0 N)

sin [π(k − f 0 N )/N ]

− 5 (N −1) sin [π (k − N + f 0 N )]

(A/2) sin

(k + f 0 N)

sin [π(k − N + f 0 N )/N ] 2. This result implies that the original frequency ω 0 of the cosine waveform has leaked into

other frequencies that form the harmonics of the time-limited sequence, and hence it is called the leakage property of cosines. It is a natural result due to the fact that bandlimited periodic cosines are sampled over noninteger periods. Explain this result using the periodic extension ˜ x(n) of x(n) and the result in Problem P5.34.1.

3. Verify the leakage property using x(n) = cos (5πn/99) R 200 (n). Plot the real and the imaginary parts of X(k) using the stem function.

P5.36 Let

x(n) =

A sin (2πℓn/N ) , 0 ≤ n ≤ N − 1 = A sin (2πℓn/N ) R

N (n)

Elsewhere

Chapter 5

THE DISCRETE FOURIER TRANSFORM

where ℓ is an integer. Notice that x(n) contains exactly ℓ periods (or cycles) of the sine waveform in N samples. This is a windowed sine sequence containing no leakage.

1. Show that the DFT X(k) is a purely imaginary sequence given by

AN

AN

X(k) =

(k − ℓ) −

δ (k − N + ℓ);

0 ≤ k ≤ (N − 1), 0<ℓ<N

2j

2j

2. Show that if ℓ = 0, then the DFT X(k) is given by

X(k) = 0;

0 ≤ k ≤ (N − 1)

3. Explain clearly how these results should be modified if ℓ < 0 or ℓ > N . 4. Verify the results of parts 1, 2, and 3 using the following sequences. Plot the imaginary

parts of the DFT sequences using the stem function.

(a) x 1 (n) = 3 sin (0.04πn) R 200 (n) (b) x 2 (n) = 5 sin 10πnR 50 (n) (c) x 3 (n) = [2 sin (0.5πn) + sin (πn)] R 100 (n) (d) x 4 (n) = sin (25πn/16) R 64 (n) (e) x 5 (n) = [4 sin (0.1πn) − 3 sin (1.9πn)] R 20 (n)

P5.37 Let x(n) = A sin (ω 0 n) R N (n), where ω 0 is a real number.

1. Using the properties of the DFT, show that the real and the imaginary parts of X(k) are given by

X(k) = X R (k) + jX I (k)

4 π (N −1)

5 sin [π (k − f 0 N )]

X R (k) = − (A/2) sin

(k − f 0 N)

sin [π(k − f 0 N )/N ]

4 + (A/2) sin π (N −1)

(k + f 5 N) sin [π (k − N + f 0 N )]

0 sin [π(k − N + f

0 N )/N ]

I (k) = − (A/2) cos

(N −1)

(k − f 0 N)

sin [π (k − f 0 N )] sin [π(k − f 0 N )/N ]

+ (A/2) cos

4 π (N −1)

5 sin [π (k − N + f

0 N )] sin [π(k − N + f 0 N )/N ]

(k + f 0 N)

2. This result is the leakage property of sines. Explain it using the periodic extension ˜ x(n) of x(n) and the result in Problem P5.36.1. 3. Verify the leakage property using x(n) = sin (5πn/99) R 100 (n). Plot the real and the imaginary parts of X(k) using the stem function.

P5.38 An analog signal x a (t) = 2 sin (4πt) + 5 cos (8πt) is sampled at t = 0.01n for n = 0, 1, . . . , N − 1 to obtain an N -point sequence x(n). An N -point DFT is used to obtain

an estimate of the magnitude spectrum of x a (t).

1. From the following values of N , choose the one that will provide the accurate estimate of the spectrum of x a (t). Plot the real and imaginary parts of the DFT spectrum X(k). (a) N = 40,

(b) N = 50,

(c) N = 60.

Problems 211

2. From the following values of N , choose the one that will provide the least amount of leakage in the spectrum of x a (t). Plot the real and imaginary parts of the DFT spectrum X(k). (a) N = 90,

(b) N = 95,

(c) N = 99.

P5.39 Using (5.49), determine and draw the signal flow graph for the N = 8 point, radix-2 decimation-in-frequency FFT algorithm. Using this flow graph, determine the DFT of the

sequence

x(n) = cos (πn/2) , 0≤n≤7

P5.40 Using (5.49), determine and draw the signal flow graph for the N = 16 point, radix-4

decimation-in-time FFT algorithm. Using this flow graph, determine the DFT of the sequence

x(n) = cos (πn/2) ,

0 ≤ n ≤ 15

P5.41 Let x(n) be a uniformly distributed random number between [−1, 1] for 0 ≤ n ≤ 10 6 . Let

h(n) = sin(0.4πn),

0 ≤ n ≤ 100

1. Using the conv function, determine the output sequence y(n) = x(n) ∗ h(n). 2. Consider the overlap-and-save method of block convolution along with the FFT

algorithm to implement high-speed block convolution. Using this approach, determine y(n) with FFT sizes of 1024, 2048, and 4096.

3. Compare these approaches in terms of the convolution results and their execution times.