You are on page 1of 36

H. C.

So Page 1 Semester A, 2001


Fourier series
Revisiting what you have learned in Advanced Mathematical Analysis
Let ) (x f be a periodic function of period 2 and is integrable over a
period. ) (x f can be represented by a trigonometric series,

! + + + + +

+ +

) 2 sin( ) 2 cos( sin cos


)) sin( ) cos( ( ) (
2 2 1 1 0
1
0
x b x a x b x a a
nx b nx a a x f
n
n n
where the coefficients are computed as



dx x f a ) (
2
1
0



dx nx x f a
n
) cos( ) (
1
and



dx nx x f b
n
) sin( ) (
1
! , 3 , 2 , 1 n
H. C. So Page 2 Semester A, 2001
Consider a continuous-time signal ) (t x periodic with period 0 > T :
) ( ) ( T t x t x + , for all t
T : fundamental period
T 2
0
: fundamental frequency (in radians/second)
) (t x can also be represented as complex exponential function
! ! + + + + + +


t j t j t j t j
t jk
k
k
e a e a a e a e a
e a t x
) 2 (
2 1 0
) (
1
) 2 (
2
0 0 0 0
0
) (
As ) (t x can be complex-valued, all
k
a s are generally complex

0
a : DC component

t j
e a
) (
1
0
t
t
: fundamental (first harmonic) components

t j
e a
) 2 (
2
0
t
t
: second harmonic components
: third harmonic components
H. C. So Page 3 Semester A, 2001
Example 1
Consider a periodic signal ) (t x , which is of the form

3
3
2
) (
k
t jk
k
e a t x

where 1
0
a , 4 1
1 1


a a , 2 1
2 2


a a , 3 1
3 3


a a .
(1) The fundamental frequency 2
0
or 1 T .
(2) ) (t x contains only (the first) three harmonic components,
function real a ) 6 cos(
3
2
) 4 cos( ) 2 cos(
2
1
1
] [
3
1
] [
2
1
] [
4
1
1
3
1
2
1
4
1
1
4
1
2
1
3
1
) (
) 6 ( 6 ) 4 ( 4 ) 2 ( 2
6 4 2 ) 2 ( ) 4 ( ) 6 (
+ + +
+ + + + + +
+ + + + + +


t t t
e e e e e e
e e e e e e t x
t j t j t j t j t j t j
t j t j t j t j t j t j
H. C. So Page 4 Semester A, 2001
DC
component
1st harmonic
component
3rd harmonic
component
2nd
harmonic
H. C. So Page 5 Semester A, 2001
As in the above example, for a real periodic signal ) (t x , its complex
conjugate equals itself, i.e. ) ( ) ( t x t x

.
Since the conjugate of
t jk
e
0

is
t jk
e
0

, we have

k k
a a or
k k
a a

, thus

+ +


1
0
1
0
} Re{ 2 ] [ ) (
0 0 0
k
t jk
k
k
t jk
k
t jk
k
e a a e a e a a t x
Writing
k
a as polar form, i.e.,
k
j
k k
e A a

, gives

+ +

1
0 0
) cos( 2 ) (
k
k k
t k A a t x

,
_



k
t jk
k
k
t jk
k
k
t jk
k
e a t x e a e a t x
0 0 0
) ( conj ) (
H. C. So Page 6 Semester A, 2001
Alternatively, write
k k k
jC B a + ,

+

1
0 0 0
)] sin( ) cos( [ 2 ) (
k
k k
t k C t k B a t x
To summarize, for a real periodic signal, the following three forms of
Fourier series representation are equivalent:
t jk
k
k
e a
0

+ +

1
0 0
) cos( 2
k
k k
t k A a

+

1
0 0 0
)] sin( ) cos( [ 2
k
k k
t k C t k B a
summation of complex
exponentials
summation of cosine
functions of non-zero phase
summation of cosine and sine
functions with zero phase
H. C. So Page 7 Semester A, 2001
Computing Fourier Series Coefficients
Given
t jk
k
k
e a t x
0
) (

,

t n k j
k
k
t jn t jk
k
k
t jn
e a e e a e t x
0 0 0 0
) (
) (


Integrating both sides from 0 to T ,


T
k
T t n k j
k
t n k j
k
k
T t jn
dt e a dt e a dt e t x
0 0
) ( ) (
0
] [ ) (
0 0 0
Knowing that

'


n k
n k T
dt e
T t n k j
, 0
,
0
) (
0
,

T t jn
n
dt e t x
T
a
0
0
) (
1
, for ! , 2 , 1 , 0 t t n
H. C. So Page 8 Semester A, 2001
Example 2
Find the Fourier series coefficients of ) sin( ) (
0
t t x .
Solution: By Eulers relation,
j
e e
t t x
t j t j
2
) sin( ) (
0 0
0


Thus 0
0
a , ) 2 ( 1
1
j a , ) 2 ( 1
1
j a

, and 0
k
a for ! , 3 , 2t t n
Example 3
Find the Fourier series coefficients of
( ) 4 2 cos ) cos( 2 ) sin( 1 ) (
0 0 0
+ + + + t t t t x .
Solution:
t j
j
t j
j
t j t j
e e e e e
j
e
j
t x
0 0 0 0
2
)
4
(
2
4
2
1
2
1
)
2
1
1 ( )
2
1
1 ( 1 ) (


+ + + + +
H. C. So Page 9 Semester A, 2001
Thus,
1
0
a , j a
2
1
1
1
, j a
2
1
1
1
+

) 1 (
4
2
2
j a + , ) 1 (
4
2
2
j a

0
k
a for ! , 4 , 3t t n
( ) ( )
2 2
} Im{ } Re{
k k k
a a a +

,
_



} Re{
} Im{
tan } {
1
k
k
k
a
a
a
Amplitude
Phase
H. C. So Page 10 Semester A, 2001
Example 4
Consider the following periodic square wave
Find its Fourier series representation.
Solution:
The signal is periodic with period T . Also, it is an even signal.
Over the specific period from 2 T to 2 T , the signal is defined as,

'

< <

otherwise , 0
, 1
) (
1 1
T t T
t x
H. C. So Page 11 Semester A, 2001
It is easy to show that

+ T t
t
t jk T t jk
k
dt e t x
T
dt e t x
T
a
0
0
0 0
) (
1
) (
1
0
Thus we can do the integration over ] 2 , 2 [ T T


1
1
0 0
1
) (
1
2
2
T
T
t jk T
T
t jk
k
dt e
T
dt e t x
T
a

For 0 k ,
T
T
dt
T
a
T
T
1
0
2
1
1
1
1

,

For 0 k ,


k
T k
e
T jk
dt e
T
a
T
T
t jk T
T
t jk
k
) sin( 1 1
1 0
0
1
1
0 1
1
0
H. C. So Page 12 Semester A, 2001
T=4T
1
T=8T
1
T=16T
1
H. C. So Page 13 Semester A, 2001
Convergence Problems of Fourier series
The problems:
1) The integral


T
t jk
dt e t x
T
0
0
) (
1

may not converge, i.e.
k
a
2) Even if all
k
a s are finite, the summation
t jk
k
k
e a
0


may not
be equal to the original signal ) (t x .
Virtually all periodic signals arising in engineering do have a Fourier
series representation, without convergence problems.
t jk
k
k
e a t x
0
) (

T
t jk
k
dt e t x
T
a
0
0
) (
1

H. C. So Page 14 Semester A, 2001
Dirichlet Conditions of Convergence
For a periodic signal ) (t x to have converged Fourier series,
1) ) (t x must be absolutely integrable over any period, i.e.

+
<
T t
t
dt t x
0
0
) ( for any
0
t
2) ) (t x has a finite number of
maxima & minima over any
period
3) ) (t x has a finite number of
discontinuous over any period

+

T t
t
dt t x
0
0
) (
unbounded
times of
oscillation
infinite number of
discontinuities
H. C. So Page 15 Semester A, 2001
Convergence at Discontinuities
1) If a periodic signal has no discontinuities, its Fourier series
representation
! converges, and
! equals the original signal at every value of t .
2) If the signal has a finite number of discontinuities in each
period, its Fourier series representation
! equals the original signal everywhere except at the
discontinuities
! converges to the midpoint of ) (t x at each discontinuity
H. C. So Page 16 Semester A, 2001
Example 5
Expanding ) (t x ,

t jk
k
k
e a t x
0
) (

, where

k
T k
a
k
) sin(
1 0
and 1
0
a
Let ) (t x
N
denote the Fourier series truncated at the Nth harmonics,
i.e.
t jk
N
N k
k N
e a t x
0
) (

) (t x
N
becomes a good approximation of ) (t x if N is large enough.

'

< <

otherwise , 0
, 1
) (
1 1
T t T
t x
H. C. So Page 17 Semester A, 2001
H. C. So Page 18 Semester A, 2001
Properties of Fourier series
Notations: The relation that
k
a s are Fourier series coefficients of ) (t x is
represented by
k
a t x
FS
) ( .
Assume
k
a t x
FS
) ( and
k
b t y
FS
) ( and ) (t x and ) (t y have
the same fundamental period T (or
0
2

).
Signal FS coefficients
Linearity ) ( ) ( t By t Ax +
k k
Bb Aa +
Time shifting
) (
0
t t x 0 0
t j
k
e a

Frequency shifting
) (
0
t x e
t jM
M k
a

H. C. So Page 19 Semester A, 2001
Signal FS coefficients
Conjugation
) (
*
t x

k
a
Time reversal ) ( t x
k
a

Time scaling ) ( t x
period changed to T
k
a
Periodic convolution


T
d t y x ) ( ) (
k k
b Ta
Multiplication ) ( ) ( t y t x

l
l k l
b a
Differentiation
dt
t dx ) (
k
a jk
0

Integration


t
dt t x ) (
k
a
jk
0
1

H. C. So Page 20 Semester A, 2001


Example 6
Derive the Fourier series representation of the following signal.
Solution:
Define ) (t g over a period,

'

<
<

4 2 2 1
2 0 2 1
) (
t
t
t g
Let
k
t g
FS
) ( , for , 0 k 0 ] )
2
1
(
2
1
[
4
1
4
2
2
0
0

dt dt
2
4
2
4
2
4
2
2
0
) 2 / sin(
)
2
1
(
4
1
2
1
4
1

,
_

,
_


jk
t jk t jk
k
e
k
k
dt e dt e , 0 k
Period T=4
H. C. So Page 21 Semester A, 2001
Alternatively, we can use properties of Fourier series to solve it.
Recalling the signal ) (t x in Example 4:
) (t g can be expressed as
2
1
) 1 ( ) ( t x t g , with 4 T & 1
1
T
By the property of time-shift,
0
) 1 (


jk
k
e a t x
FS

2
) 1 (


k j
k
e a t x
FS
Subtracting the DC offset of 2 1 from
0
a ,

'

'




0 , 0
0 ,
) 2 sin(
0 , 2 1
0 ,
2
0
2
k
k e
k
k
k a
k e a
k j
k j
k
k
,
) sin(
1 0

k
T k
a
k
2 / 1 / 2
1 0
T T a
H. C. So Page 22 Semester A, 2001
Note that when we chose the interval [0,4):

,
_

+

,
_


,
_

,
_

4
2
2
2
0
2
2
1
4
1
2
1
4
1
dt e dt e a
t jk t jk
k
1
1
1
]
1

,
_

,
_

,
_

,
_

4
2
2
2
0
2
4
2
2
2
0
2
4
1
2 /
1
8
1
2 /
1
8
1
t jk t jk
t jk t jk
e e
jk
e
jk
e
jk
[ ] ) ( 1
4
1
2


jk k j jk
e e e
jk
H. C. So Page 23 Semester A, 2001
[ ] k e e
jk
k j jk
integer for 1 1
2
1
2



"
On the other hand, if we choose [-2,2)

,
_

+

,
_



,
_

,
_

2
0
2
0
2
2
2
1
4
1
2
1
4
1
dt e dt e a
t jk t jk
k
[ ]
2 /
2 /
2 / 2 / 2 /
) 2 / sin(
) 2 / sin( 2
2
1
2
1



jk
jk
jk jk jk
e
k
k
k j e
jk
e e e
jk
H. C. So Page 24 Semester A, 2001
[ ]
[ ]
2 /
2
0
2
0
2
2
2
0
2
0
2
2
) 2 / sin(
1
2
1
) 1 ( ) 1 (
4
1
4
1
2 /
1
8
1
2 /
1
8
1

,
_

,
_

,
_

,
_


1
1
1
]
1


jk jk
jk jk
t jk t jk
t jk t jk
e
k
k
e
jk
e e
jk
e e
jk
e
jk
e
jk
You can choose intervals [3,7), [4,8), etc. Make use of
1
2

k j
e you can get the same answer.
H. C. So Page 25 Semester A, 2001
Fourier series of even & odd signals
Real even signals
By the property of time reversal, we have
k
a t x


FS
) ( .
) (t x is even ) ( ) ( t x t x
k
a t x


FS
) (
) (t x is real
k k
a a


k
a t x
FS
) (
Therefore, we have

k k
a a for all < < k .
For a real even signal
1) } {
k
a are real:

k k
a a
2) } {
k
a are even:
k k
a a

) cos( 2 ) ( ) (
0
1
0
1
0
0 0
t k a a e e a a t x
k
k
t jk t jk
k
k

+ +

H. C. So Page 26 Semester A, 2001


Real odd signals
Similar to the above derivation, we have


k k
a a .

For a real odd signal
1) } {
k
a are purely imaginary:


k k
a a
2) } {
k
a are odd:
k k
a a


3) ; 0
0
a
Let
k k
jC a , where
k
C is real and
k k
C C


) sin( 2 ) ( ) (
0
1 1
0 0
t k C e e jC t x
k
k
t jk t jk
k
k

H. C. So Page 27 Semester A, 2001


Parsevals Theorem

Recall
t jk
k
k
e a t x
0
) (

The total average power over a period equals the sum of the
average powers in all of the harmonic components.

k
k
T
a dt t x
T
2 2
) (
1
2
2
0
1
k
T
t jk
k
a dt e a
T


Average power
over a period
Sum of squared
magnitudes of all
harmonics
Average power of
the kth harmonic
H. C. So Page 28 Semester A, 2001
Proof:

,
_


,
_

m
m
T
T
t n m j
n
n m
m
n
t jn
n
T
T
m
t jm
m
T
T
a
dt e a a
T
dt e a e a
T
dt t x
T
2
2 /
2 /
) ( *
*
2 /
2 /
2 /
2 /
2
| |
1
1
| ) ( |
1
0
0 0
Example 7
Suppose we want to use ) (t g
N
to approximate ) (t g of Example 6
where ) (t g
N
denotes the Fourier series truncated at the Nth
harmonics, i.e.
t jk
N
N k
k N
e t g
0
) (

. What is the minimum value of


N so that ) (t g
N
contains at least 90% power of ) (t g ?
H. C. So Page 29 Semester A, 2001
Solution:
Average power of ) (t g =
4
1
)
2
1
(
4
1
) (
1
2
4
0
2
0

dt dt t g
T
T
Try 1 N , we have
2026 . 0
2 ) 2 / ( sin
2
2 2
2
2
1
2
1
2
1
1



k
k
Try 2 N ,
2 2
2
2
2
2
2
2
2
2
2
2
2 ) ( sin
2
2 2

+ +



k
k
odd is , 0 k
k

Try 3 N , we have
4
1
9 . 0
9
20
) 3 (
) 2 / 3 ( sin
2
2 2
2 2
2
2
2
3
2
3
2
2
3
3
>

+ +



k
k
Hence the minimum value of N is 3.
H. C. So Page 30 Semester A, 2001
Discrete-time Fourier Series
! Fourier Series is a frequency analysis tool for continuous-time
periodic signals while Discrete-Time Fourier Series (DTFS) is
used for analyzing discrete-time periodic signals
! In fact, DTFS can be derived from the Fourier Series (I can show
you if you are interested on this)
! Similar to continuous-time case, a discrete-time signal ] [n x is
periodic with fundamental period N if
] [ ] [ N n x n x +
where N is the smallest integer for which the equation holds. The
fundamental frequency is defined as N / 2
0
.
! However, notice that sampling a continuous-time periodic signal
does not necessarily give a discrete-time periodic sequence.
H. C. So Page 31 Semester A, 2001
Example 8
Consider a continuous-time periodic signal ) 5 . 0 cos( ) ( t t x .
Sampling ) (t x with a sampling period of 1s gives
} ), 1 cos( ), 5 . 0 cos( ), 0 cos( ), 5 . 0 cos( { ]} [ { ! ! n x
] [n x is not periodic
Consider another continuous-time periodic signal ) 5 . 0 cos( ) ( t t y .
Sampling ) (t y with a sampling period of 1s yields
} , 0 , 1 , 0 , 1 , 0 {
} ), cos( ), 5 . 0 cos( ), 0 cos( ), 5 . 0 cos( { ]} [ {
! !
! !

n y
] [n y is periodic and the fundamental period is 2 N
We can use DTFS to analyze ] [n y but not ] [n x . In fact, we can use
discrete-time Fourier transform (DTFT), which will be discussed
later, to analyze ] [n x .
H. C. So Page 32 Semester A, 2001
Fourier Series & LTI Systems
The output of a continuous-time periodic signal ) (t x to a LTI system
with impulse response ) (t h is given by




d t h x t h t x t y ) ( ) ( ) ( ) ( ) (
where ) (t y is also periodic with the same fundamental frequency as
) (t x . That is, if
t jk
k
k
t jk
k
k
e b t y e a t x
0 0
) ( ) (

only phases and magnitudes are changed


H. C. So Page 33 Semester A, 2001
Proof:


d t x h d t h x t h t x t y ) ( ) ( ) ( ) ( ) ( ) ( ) (
Consider the k th component of ) (t x , i.e.,
t jk
k
e a
0

. The system
output due to this component is:



d e h a e
d e a h t y
jk
k
t jk
t jk
k k
0 0
0
) (
) ( ) (
) (
where we can see that





d e h a b
jk
k k
0
) (
Combining all harmonic components, we have
t jk
k
k
k
k
e b t y t y
0
) ( ) (

H. C. So Page 34 Semester A, 2001


Example 9
Given a LTI system with impulse response ) ( ) ( t u e t h
t
and an
input signal ) 2 cos( 5 . 0 ) ( t t x . Find the system output ) (t y .
Solution:




+
+
+


0
) 2 1 ( 2
0
) 2 1 ( 2
0
2 2
0
2 2
0
) ( 2 ) ( 2
0
) 2 1 (
1
4
1
) 2 1 (
1
4
1
4
1
4
1
) (
4
1
)) ( 2 cos(
2
1
)) ( 2 cos(
2
1
) ( ) ( ) ( ) (
e
j
e e
j
e
d e e e d e e e
d e e e d t e
d t u e d t x h t y
t t
j t j t
t j t j
H. C. So Page 35 Semester A, 2001
( )
) 2 sin(
) 4 1 ( 2
2
) 2 cos(
) 4 1 ( 2
1
) 2 sin( 2 ) 2 cos(
) 4 1 ( 2
1
2 1
2 1
2 1
) 2 sin( ) 2 cos(
Re
2
1
2 1
) 2 sin( ) 2 cos(
Re
2
1
2 1
Re
4
2
2 1 2 1 4
1
2 1 2 1 4
1
) (
2 2
2
2
*
2 2 2 2
t t
t t
j
j
j
t j t
j
t j t
j
e
j
e
j
e
j
e
j
e
t y
t
t t t t

+
+

+
+

'

+
+

'

+
+

'

,
_

,
_

+
+
+

,
_


+
+


H. C. So Page 36 Semester A, 2001
Express ) (t y as a function of ) 2 cos( t only, we get
( )
( ) ) 2 ( tan 2 cos
4 1 2
1
) 2 sin( )) 2 ( sin(tan ) 2 cos( )) 2 ( cos(tan
4 1 2
1
) 2 sin(
4 1
2
) 2 cos(
4 1
1
4 1 2
1
) (
1
2
1 1
2
2 2 2

+

+
+

,
_

+
+ +


t
t t
t t t y
Comparing ) (t x ( ) 2 cos( 5 . 0 t ) and ) (t y , we see that they are of the
same frequency but their phases and magnitudes are different.
Nevertheless, we notice that computing the convolution is tedious
even for simple signal and system. We will solve this problem again
with the use of Fourier transform, which is shown to be easier.

You might also like