Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                

Assignment 4 Solutions 10

Download as pdf or txt
Download as pdf or txt
You are on page 1of 11

5

Chapter 3

Continuous-Time Fourier Series


(Chapter 4)

4.1 Find the Fourier series representation (in complex exponential form) of each of the signals given below. In each
case, explicitly identify the fundamental period and Fourier series coefficient sequence ck .
(a) x(t) = 1 + cos π t + sin2 π t;
(b) x(t) = [cos 4t][sint]; and
ax
(c) x(t) = |sin 2π t|. [Hint: eax sin bxdx = e [a sina2bx−b cos bx]
R
+b2
+ C, where a and b are arbitrary complex and
nonzero real constants, respectively.]

Solution.

(a) We can rewrite x(t) in the form of a Fourier series by simple algebraic manipulation as follows:

x(t) = 1 + cos π t + sin2 π t


i2
= 1 + 12 [e jπ t + e− jπ t ] +
 jπ t
e − e− jπ t
h
1
2j

= 1 + 12 e jπ t + 12 e− jπ t − 41 [e j2π t − 2 + e− j2π t ]
= − 41 e− j2π t + 21 e− jπ t + 32 + 21 e jπ t − 41 e j2π t .

Thus, we have that


x(t) = ∑ ck e jkω0t ,
k=∞

where ω0 = π (i.e., T = 2) and

3
for k = 0
 12



2 for k = ±1
ck =
−1 for k = ±2
 4



0 otherwise.

2π 2π
(c) The signal x(t) is periodic with period T = 1
2 and frequency ω0 = T = 1/2 = 4π . From the Fourier series

Last Revised: May 9, 2010 Copyright c 2003–2010 Michael D. Adams


6 CHAPTER 3. CONTINUOUS-TIME FOURIER SERIES (CHAPTER ??)

analysis equation, we have


Z
ck = 1
T x(t)e− jkω0 t dt
T
Z 1/2
= 1
1/2 |sin 2π t| e− jk4π t dt
0
Z 1/2
=2 e− j4π kt sin 2π tdt
0

e− j4π kt [− j4π k sin 2π t − 2π cos 2π t]


  1/2
=2
(− j4π k)2 + (2π )2 0
i 1/2
2(2π ) − j4π kt
h
= −16π 2 k2 +4π 2 e [− j2k sin 2π t − cos 2π t]
0
− j4π k/2
h i
1
= π (1−4k2 ) e [− j2k sin 2π /2 − cos 2π /2] − [− cos 0]
= 1
π (1−4k2 )
[e− j2π k [− j2k sin π − cos π ] + cos 0]
1
= π (1−4k2 )
[2]
2
= .
π (1 − 4k2 )

Since the integral table entry given (i.e., for the integral eax sin bxdx) is valid for the case of a = 0, we did not
R

need to assume that k 6= 0 in the above integration. Therefore, the above expression is valid for all k. Thus, we
have that


x(t) = ∑ ck e jkω0 t ,
k=−∞

where ω0 = 4π and

2
ck = .
π (1 − 4k2 )

4.2 For each of the signals shown in the figure below, find the corresponding Fourier series coefficient sequence.

x(t)
1 1

··· ···
t
−4 −3 −2 −1 1 2 3 4

− 21 − 21

(a)

Copyright c 2003–2010 Michael D. Adams Last Revised: May 9, 2010


7

x(t)
1

··· ···
t
−T − A2 −T −T + A2 − A2 0 A
2 T − A2 T T + A2

(b)

x(t)
2

1
··· ···
t
−7 −6 −5 −4 −3 −2 −1 0 1 2 3 4 5 6 7

(c)

x(t)

1
··· ···
t
−3 −2 −1 1 2 3

−1

(d)

Solution.

(a) We calculate the fundamental frequency ω0 as

2π 2π
ω0 = T = 4 = π2 .


(So, we have T = π /2 = 4.) From the Fourier series analysis equation, we have

Z
ck = 1
T x(t)e− jkω0 t dt
T
Z 2
= 1
4 [δ (t − 1) − 21 δ (t + 1)]e− jπ kt/2 dt
−2
Z 2 Z 2 
= 1
4 δ (t − 1)e− jπ kt/2 dt − 12 δ (t + 1)e− jπ kt/2 dt
−2 −2
1 − jπ k/2
= 4 [e − 21 e jπ k/2 ]
1 − jπ k/2
= 4e − 81 e jπ k/2 .


(c) The signal x(t) is periodic with period T = 5 and frequency ω0 = 5 . From the Fourier series analysis

Last Revised: May 9, 2010 Copyright c 2003–2010 Michael D. Adams


8 CHAPTER 3. CONTINUOUS-TIME FOURIER SERIES (CHAPTER ??)

equation, we can write


Z
ck = 1
T x(t)e− jkω0 t dt
T
Z 5/2
= 1
5 x(t)e− j2π kt/5 dt
−5/2
Z −1 Z 1 Z 2 
= 1
5 e− j2π kt/5 dt + 2e− j2π kt/5 dt + e− j2π kt/5 dt
−2 −1 1
Z 2 Z 1 
1 − j2π kt/5 − j2π kt/5
= 5 e dt + e
−2 −1
h i2 i1 
− j2π kt/5 − j2π kt/5
h
1 1 1
= 5 − j2π k/5 e + − j2π k/5 e
−2 −1
 
2 1
− j2π kt/5
= 1
− j2π k e + e− j2π kt/5
−2 −1
− j4π k/5
− e j4π k/5 + e− j2π k/5 − e j2π k/5
h i
1
= − j2π k e

− j2π k [−2 j sin 4π k/5 − 2 j sin 2π k/5]


1
=

π k [sin 4π k/5 + sin 2π k/5]


1
=
sin 4π k/5 sin 2π k/5
= +
πk πk
= 45 sinc 4π k/5 + 52 sinc 2π k/5.

In the above derivation, we assumed that k 6= 0. So, now we must consider the case of k = 0. From the Fourier
series analysis equation, we have
Z
1
c0 = T x(t)dt
T
Z 5/2
1
= 5 x(t)dt
−5/2
Z −1 Z 1 Z 2 
1
= 5 dt + 2dt + dt
−2 −1 1
1
= 5 [1 + 4 + 1]
6
= 5.

Therefore, we have that


(
6
5 for k = 0
ck = 4
5 sinc 4π k/5 + 52 sinc 2π k/5 otherwise
= 45 sinc 4π k/5 + 52 sinc 2π k/5.

The first few coefficients are approximately as follows:

c0 = 1.2, c1 = c−1 ≈ 0.489828, and c2 = c−2 ≈ −0.057816.

4.6 A periodic signal x(t) with period T and Fourier series coefficient sequence ck is said to be odd harmonic if
ck = 0 for all even k.
(a) Show that if x(t) is odd harmonic, then x(t) = −x(t − T2 ) for all t.
(b) Show that if x(t) = −x(t − T2 ) for all t, then x(t) is odd harmonic.

Copyright c 2003–2010 Michael D. Adams Last Revised: May 9, 2010


9

Solution.

(b) From the Fourier series analysis equation, we have


Z
ck = 1
T x(t)e− jkω0 t dt
T
T /2 Z T
Z 
1 − jkω0 t − jkω0 t
= T x(t)e dt + x(t)e dt .
0 T /2

Now, we employ a change a variable in the second integral. Let λ = t + T /2 so that t = λ − T /2 and d λ = dt.
Applying this change of variable, we obtain

T /2 Z 3T /2
Z 
ck = 1
T x(t)e− jkω0 t dt +
x(λ − T2 )e− jkω0 (λ −T /2) d λ
0 T
Z T /2 Z 3T /2 
− jkω0 t − jkω0 (λ −T /2)
=T 1
x(t)e dt + −x(λ )e dλ
0 T
Z T /2 Z 3T /2 
− jkω0 t jkω0 T /2 − jkω0 λ
=T 1
x(t)e dt − x(λ )e e dλ
0 T
Z T /2 Z 3T /2 
= T1 x(t)e− jkω0 t dt − e jkπ x(λ )e− jkω0 λ d λ .
0 T

Now, we rename the dummy variable of integration in the second integral from λ to t. This yields

T /2 Z 3T /2
Z 
1 − jkω0 t jπ k − jkω0 t
ck = T x(t)e dt − e x(t)e dt
0 T
T /2 Z T /2
Z 
1 − jkω0 t k − jkω0 t
= T x(t)e dt − (−1) x(t)e dt
0 0
 Z T /2 
= T1 (1 − (−1)k ) x(t)e− jkω0 t dt
0

x(t)e− jkω0 t dt for odd k


( R
2 T /2
= T 0
0 for even k.

Therefore, ck = 0 for even k.

A LTERNATIVE SOLUTION . From the Fourier series analysis equation, we have


Z
ck = 1
T x(t)e− jkω0 t dt
T
Z
= 1
T (−x(t − T /2))e− jkω0 t dt
T
Z
= − T1 x(t − T /2)e− jkω0 t dt
T
Z α +T
= − T1 x(t − T /2)e− jkω0 t dt.
α

Now, we employ a change of variable. Let v = t − T /2 so that t = v + T /2 and dv = dt. Applying the change

Last Revised: May 9, 2010 Copyright c 2003–2010 Michael D. Adams


10 CHAPTER 3. CONTINUOUS-TIME FOURIER SERIES (CHAPTER ??)

of variable, we obtain
Z α +T /2
ck = − T1 x(v)e− jkω0 (v+T /2) dv
α −T /2
Z
= − T1 x(v)e− jkω0 v e− jkω0 T /2 dv
T
Z
= − T1 x(v)e− jkω0 v e− jk(2π /2) dv
T
 Z 
= (−1)k − T1 x(v)e− jkω0 v dv
T
k
= (−1) (−ck )
= (−1)k+1 ck .

So, we have that ck = (−1)k+1 ck . If k is even, then ck = −ck . This implies, however, that ck = 0. Therefore, for
even k, we have that ck = 0.

4.8 Find the Fourier series coefficient sequence ck of the periodic signal x(t) shown in the figure below. Plot the
frequency spectrum of this signal including the first five harmonics.

x(t)

1
··· ···
t
−2 −1 0 1 2 3

Solution.
The signal x(t) is periodic with period T = 2, and frequency ω0 = 2Tπ = 22π = π . From the Fourier series analysis
equation, we have
Z
ck = 1
T x(t)e− jkω0 t dt
T
Z 2
= 1
2 x(t)e− jπ kt dt
0
Z 1
= 1
2 e− jπ kt dt
0
1
− jπ kt
h i
1 1
= 2 − jπ k e 0
i1
− jπ kt
h
= j2−1
πk e 0
− jπ k
h i
1
= j2π k 1 − e
h i
= j21π k 1 − (−1)k
(
− πjk for odd k
=
0 for even k

Since we assumed that k 6= 0 in the derivation above, we must now consider the case of k = 0. From the Fourier

Copyright c 2003–2010 Michael D. Adams Last Revised: May 9, 2010


11

series analysis equation, we have


Z
1
c0 = T x(t)dt
T
Z 2
1
= 2 x(t)dt
0
Z 1
1
= 2 dt
0
= 21 [t]|10
= 12 .

Thus, we have

1
2
 for k = 0
ck = − πjk for odd k

0 for even k, k 6= 0

Calculating the first several Fourier series coefficients yields the following:

k |ck | arg ck
1
0 2 0
1 π1 − π2
2 0 0
3 31π − π2
4 0 0
5 51π − π2

|ck |

1
2

··· ···
ω
−4ω0 −3ω0 −2ω0 −ω0 0 ω0 2ω0 3ω0 4ω0

∠ck

π
2

···
ω
−4ω0−3ω0 −2ω0 −ω0 ω0 2ω0 3ω0 4ω0

···
− π2

Last Revised: May 9, 2010 Copyright c 2003–2010 Michael D. Adams


12 CHAPTER 3. CONTINUOUS-TIME FOURIER SERIES (CHAPTER ??)

4.9 Suppose that we have a LTI system with frequency response


(
1 for |ω | ≥ 5
H( jω ) =
0 otherwise.

Using frequency-domain methods, find the output y(t) of the system if the input x(t) is given by

x(t) = 1 + 2 cos 2t + 2 cos 4t + 21 cos 6t.

Solution.
We begin by finding the Fourier series representation of x(t). Using Euler’s relation, we can rewrite x(t) as

x(t) = 1 + 2 cos 2t + 2 cos 4t + 12 cos 6t


h i
= 1 + 2 21 (e j2t + e− j2t ) + 2 12 (e j4t + e− j4t ) + 12 21 (e j6t + e− j6t )
   

= 1 + e j2t + e− j2t + e j4t + e− j4t + 14 e j6t + 41 e− j6t .

Thus, we have that the Fourier series representation of x(t) is given by



x(t) = ∑ ak e jkω0 t ,
k=−∞

where ω0 = 2 and



1 for k = 0
for k = ±1

1


ak = 1 for k = ±2
1

for k = ±3



 4
0 otherwise.

Since the system is LTI, we know that the output y(t) has the form

y(t) = ∑ bk e jkω0 t ,
k=−∞

where bk = ak H( jkω0 ). Using the results from above, we can calculate the bk as follows:

b0 = a0 H( j[0][2]) = 0,
b1 = a1 H( j[1][2]) = 0,
b−1 = a−1 H( j[−1][2]) = 0,
b2 = a2 H( j[2][2]) = 0,
b−2 = a−2 H( j[−2][2]) = 0,
b3 = a3 H( j[3][2]) = 41 (1) = 41 , and
1 1
b−3 = a−3 H( j[−3][2]) = 4 (1) = 4 .

Thus, we have
(
1
4 for k = ±3
bk =
0 otherwise.

Copyright c 2003–2010 Michael D. Adams Last Revised: May 9, 2010


13

Therefore, the output y(t) is given by

y(t) = 41 e− j6t + 41 e j6t


= 14 [e− j6t + e j6t ]
= 41 [2 cos 6t]
= 12 cos 6t.

4.101 Consider the periodic signal x(t) shown in Figure B of Problem 4.2 where T = 1 and A = 21 . We can show that
this signal x(t) has the Fourier series representation

x̂(t) = ∑ ck e jkω0 t
k=−∞

where ck = 21 sinc π2k and ω0 = 2π . Let x̂N (t) denote the above infinite series truncated after the Nth harmonic
component. That is,
N
x̂N (t) = ∑ ck e jkω0 t .
k=−N

(a) Use MATLAB to plot x̂N (t) for N = 1, 5, 10, 50, 100. You should see that as N increases, x̂N (t) converges to
x(t). [HINT: You may find the sym, symsum, subs, and ezplot functions useful for this problem. Please note
that the MATLAB sinc function is NOT defined in the same way as in the lecture notes. The MATLAB sinc
function is defined as sinc x = (sin(π x))/(π x). So, it might be wise to avoid the use of this MATLAB function
altogether.]
(b) By examining the graphs obtained in part (a), answer the following: As N → ∞, does x̂N (t) converge to x(t)
uniformly (i.e., equally fast) everywhere? If not, where is the rate of convergence slower?
(c) The signal x(t) is not continuous everywhere. For example, the signal has a discontinuity at t = 41 . As
N → ∞, to what value does x̂N (t) appear to converge at this point? Again, deduce your answer from the graphs
obtained in part (a).
Solution.
(a) The graphs necessary in this problem can be generated using the code given below.

Listing 3.1: main.m


clear all

for n = [1 5 10 50 100]
% Sum the appropriate number of terms.
f = symsum ( sym ( ’0.5 * mysinc ( pi * k / 2) * exp (j * k * w * t) ’), ...
’k ’, -n , n );
% Plot the result.
ezplot ( subs (f , ’w ’, 2 * pi ), [ -1 1]);
title ( sprintf ( ’x_ {% d }( t) ’, n ));
% Pause for a moment so that the graph does not disappear too quickly.
pause (1);
% Print the graph to a file.
eval ( sprintf ( ’ print -dps data / sqrwav_ %d. ps ’, n ));
end

Last Revised: May 9, 2010 Copyright c 2003–2010 Michael D. Adams


14 CHAPTER 3. CONTINUOUS-TIME FOURIER SERIES (CHAPTER ??)

Listing 3.2: mysinc.m

function y = mysinc (x)


% mysinc - Compute the sinc function (as defined in the lecture notes)
% sinc(x) returns a matrix whose elements are the sinc of the
% elements of x

% Initialize the output array to all ones.


y = ones ( size (x ));
% Determine the indices of all nonzero elements in the input array.
i = find (x );
% Compute the sinc function for all nonzero elements.
% The zero elements are already covered, since the output
% array was initialized to all ones above.
y(i) = sin (x(i )) ./ (x(i ));
return

Using the above code, we obtain the graphs given below.

Copyright c 2003–2010 Michael D. Adams Last Revised: May 9, 2010


15

x (t) x (t)
1 5

1.2
1.2

1
1

0.8 0.8

0.6 0.6

0.4 0.4

0.2 0.2

0
0

−0.2
−0.2
−1 −0.8 −0.6 −0.4 −0.2 0 0.2 0.4 0.6 0.8 1 −1 −0.8 −0.6 −0.4 −0.2 0 0.2 0.4 0.6 0.8 1
t t

x (t) x (t)
10 50

1.2 1.2

1 1

0.8 0.8

0.6 0.6

0.4 0.4

0.2 0.2

0 0

−0.2 −0.2
−1 −0.8 −0.6 −0.4 −0.2 0 0.2 0.4 0.6 0.8 1 −1 −0.8 −0.6 −0.4 −0.2 0 0.2 0.4 0.6 0.8 1
t t

x100(t)
1.2

0.8

0.6

0.4

0.2

−1 −0.8 −0.6 −0.4 −0.2 0 0.2 0.4 0.6 0.8 1


t

(b) The function x̂N (t) does not converge to x(t) uniformly (i.e., at the same rate everywhere). The rate of
convergence is (relatively) lower at/near the points of discontinuity of x(t).
(c) At the point of discontinuity of x(t) located at t = 41 , the function x̂N (t) appears to converge to the average
of the left and right limits of x(t) at that point, namely the value of 12 .

Last Revised: May 9, 2010 Copyright c 2003–2010 Michael D. Adams

You might also like