Revision of Fourier Series
Revision of Fourier Series 2
Odd and Even FunctionsAn even function is a function that is symmetric about the value t = 0, i.e. f(t) = f(-t)
An odd function is a function that is anti- symmetric about the value t = 0, i.e. -f(t) = f(-t)
even/symmetric function
odd/anti-symmetric function
Revision of Fourier Series 3
A Fourier series is a series of sine and cosine terms whose frequencies are integer multiples of a common fundamental angular frequency ω,
where and T is the fundamental period.
The numbers an and bn are called the Fourier coefficients of the series.
Fourier Series
10 n n2
n 1 n 1
f(t) a a cos(n t) b sin(n t)∞ ∞
= =
= + ω + ω∑ ∑
2Tπ
ω =
Revision of Fourier Series 4
Fourier SeriesThe Fourier coefficients are given by
The constant term, , is the average or mean value of the function.
T2
0 T0
a f(t)dt= ∫
( )T
2n T
0
a f(t)cos n t dt= ω∫ ( )T
2n T
0
b f(t)sin n t dt= ω∫
102 a
Revision of Fourier Series 5
Main FormulaeThe following standard integrals are useful when evaluating Fourier components.
[ ]dg dfdt dtf(t) dt f(t)g(t) g(t)dt= −∫ ∫
1sin t dt cos tωω = − ω∫ 1cos t dt sin tωω = ω∫
( )21t sin t dt sin t t cos tω
ω = ω − ω ω∫ ( )21t cos t dt cos t t sin tω
ω = ω + ω ω∫
Integration by Parts:
Revision of Fourier Series 6
Main Formulae
( )32 2 21t sin t dt 2 t sin t 2cos t t cos t
ωω = ω ω + ω − ω ω∫
( )32 2 21t cos t dt t sin t 2 t cos t 2sin t
ωω = ω ω + ω ω − ω∫
( )2 2at at at1
ae sin t dt ae sin t e cos t
ω +ω = ω − ω ω∫
( )2 2at at at1
ae cos t dt ae cos t e sin t
ω +ω = ω + ω ω∫
Revision of Fourier Series 7
Main Formulae
( ) ( )( )1 1 12cos( t)cos( t)dt sin t sin tω−φ ω+φ
⎡ ⎤ ⎡ ⎤ω φ = ω− φ + ω+ φ⎣ ⎦ ⎣ ⎦∫
( ) ( )( )1 1 1 12 2cos( t)sin( t)dt cos t cos tω−φ ω+φ
⎡ ⎤ ⎡ ⎤ω φ = ω−φ − ω+ φ⎣ ⎦ ⎣ ⎦∫
( ) ( )( )1 1 12sin( t)sin( t)dt sin t sin tω−φ ω+φ
⎡ ⎤ ⎡ ⎤ω φ = ω−φ − ω+φ⎣ ⎦ ⎣ ⎦∫
Revision of Fourier Series 8
Before doing any examples it is wise to note some time- saving results
Odd and Even Functions
If a function f(t) is periodic and symmetric/even then it will have a Fourier series containing only cosine terms, i.e. bn = 0 if f(t) = f(-t).
If a function f(t) is periodic and antisymmetric/odd then it will have a Fourier series containing only sine terms, i.e. an = 0 if f(t) = -f(-t).
Revision of Fourier Series 9
Discontinuous FunctionsWhen integrating discontinuous functions, split the integral into sections;
e.g. if
then
1
2
f (t), 0 t af(t)
f (t), a t T≤ ≤⎧
= ⎨ < <⎩
T a T
1 20 0 a
f(t)dt f (t)dt f (t)dt= +∫ ∫ ∫
Revision of Fourier Series 10
Determine the Fourier series of the periodic, rectangular pulse function defined by
Example 1
A, 0 t 1f(t) , f(t 2) f(t)
0, 1 t 2≤ ≤⎧
= + =⎨ < <⎩
0 0.5 1 1.5 2 2.5 3 3.5 4
Revision of Fourier Series 11
Example 1The function f(t) has period T = 2, so
The Fourier series will have the form
Since the function is neither symmetric nor anti-symmetric we have to work out both an and bn coefficients;
2Tπ
ω = = π
10 n n2
n 1 n 1
a a cos( nt) b sin( nt)∞ ∞
= =
+ π + π∑ ∑
Revision of Fourier Series 12
Example 1[ ]
T 2 1 212
0 T 00 0 0 1
a f(t)dt f(t)dt A dt 0dt At A= = = + = =∫ ∫ ∫ ∫
( )T 2
2n T
0 01 2
0 11A A A
n n n0
a f(t)cos n t dt f(t)cos(n t)dt
A cos(n t)dt 0dt
sin(n t) sin(n ) sin(0) 0π π π
= ω = π
= π +
⎡ ⎤ ⎡ ⎤ ⎡ ⎤= π = π − =⎣ ⎦ ⎣ ⎦ ⎣ ⎦
∫ ∫
∫ ∫
So a0 = A
So an = 0 for n > 0
Revision of Fourier Series 13
Example 1( )
T 22
n T0 0
1 21A
n 00 1
nA A An n n 2A
n
b f(t)sin n t dt f(t)sin(n t)dt
A sin(n t)dt 0dt cos(n t)
0, n evencos(n ) cos(0) ( ( 1) 1)
, n odd
π
π π ππ
= ω = π
⎡ ⎤= π + = − π⎣ ⎦
⎧⎪⎡ ⎤ ⎡ ⎤= − π − − = − − + = ⎨⎣ ⎦ ⎣ ⎦ ⎪⎩
∫ ∫
∫ ∫
So 2A 2A 2A 2A1 2 3 4 5 6 73 5 7b ,b 0,b ,b 0,b ,b 0,b ,π π π π= = = = = = =
and the Fourier Series is:
( )1 2 2 2 22 3 5 7f(t) A sin( t) sin(3 t) sin(5 t) sin(7 t)π π π π= + π + π + π + π +L
Revision of Fourier Series 14
Example 1
0 0.5 1 1.5 2 2.5 3 3.5 4
1
0 0.5 1 1.5 2 2.5 3 3.5 4
1
Fundamental only
1st - 3rd harmonics
0 0.5 1 1.5 2 2.5 3 3.5 4
1
0 0.5 1 1.5 2 2.5 3 3.5 4
1
1st - 7th harmonics
1st - 15th harmonics
Revision of Fourier Series 15
Example 2Determine the Fourier series of the symmetric periodic function defined by
t 0 tf(t) , f(t 2 ) f(t)
2 t t 2≤ ≤ π⎧
= + π =⎨ π − π < < π⎩
0 2 4 6 8 10 12
1
2
3
Revision of Fourier Series 16
Example 2The function f(t) has period T = 2π, so
and
The coefficients an and bn can be deduced from the general formula; but since the function is symmetric all sine terms vanish, i.e. all bn = 0.
2 2 1T 2π π
ω = = =π
10 n n2
n 1 n 1
a a cos(nt) b sin(nt)∞ ∞
= =
+ +∑ ∑
Revision of Fourier Series 17
Example 2Then
so a0 = π
( ) ( ) ( ) ( )( )
2 21 1
00 0
22 21 1 12 20
2 2 2 2 21 1 12 2
a f(t)dt t dt (2 t)dt
t 2 t t
0 4 2 2
π π π
π ππ
π π
π π
π
⎛ ⎞= = + π −⎜ ⎟⎜ ⎟
⎝ ⎠⎛ ⎞⎡ ⎤ ⎡ ⎤= + π −⎜ ⎟⎣ ⎦ ⎣ ⎦⎝ ⎠
= π − + π − π − π − π = π
∫ ∫ ∫
Revision of Fourier Series 18
2 2
2 2
2 21 1
n0 0
221 1 1 1 1
n n nn n0
1 1 1 1n nn n
21n
a f(t)cos(nt)dt t cos(nt)dt (2 t)cos(nt)dt
cos(nt) t sin(nt) sin(nt) cos(nt) t sin(nt)
cos(n ) sin(n ) cos(0) 0sin(0)
si
π π π
π ππ
π ππ
π π
ππ
⎛ ⎞= = + π −⎜ ⎟⎜ ⎟
⎝ ⎠⎛ ⎞⎡ ⎤ ⎡ ⎤= + + − −⎜ ⎟⎣ ⎦ ⎣ ⎦⎝ ⎠
⎡ ⎤ ⎡ ⎤π + π π − +⎣ ⎦ ⎣ ⎦
= +
∫ ∫ ∫
( ) ( )
2
2
2 2 2 2 2
1 1nn
2 1 1n nn
n 2 n1 1 1 1 1 1 2n n n n n
n(2 n) cos(2 n) 2 sin(2 n)
sin(n ) cos(n ) sin(n )
( 1) ( 1) ( 1) 1
π
π π
⎛ ⎞⎜ ⎟⎜ ⎟⎡ ⎤π − π − π π⎜ ⎟⎣ ⎦⎜ ⎟
⎡ ⎤⎜ ⎟− π − π − π π⎣ ⎦⎝ ⎠
⎡ ⎤ ⎡ ⎤ ⎡ ⎤ ⎡ ⎤ ⎡ ⎤= − − + − − − − = − −⎣ ⎦⎣ ⎦ ⎣ ⎦ ⎣ ⎦ ⎣ ⎦
Example 2Also
24
n n na 0 if n is even, and a if n is odd−
π= =i.e.
Revision of Fourier Series 19
0 2 4 6 8 10 12
1
2
3
0 2 4 6 8 10 12
1
2
3
Fundamental only
1st - 3rd harmonics
0 2 4 6 8 10 12
1
2
3
0 2 4 6 8 10 12
2
1st - 7th harmonics
1st - 15th harmonics
Example 2
4 4 4 42 9 25 49f(t) cos(t) cos(3t) cos(5t) cos(7t)π
π π π π= − − − − −L
Hence
Revision of Fourier Series 20
Determine the Fourier series of the anti-symmetric periodic function defined by
Example 3
1 12 2f(t) t t f(t 1) f(t)= − ≤ ≤ + =
1.5 1 0.5 0 0.5 1 1.5
0.5
0.5
Revision of Fourier Series 21
Example 3The function f(t) has period T = 1, so
Hence
The coefficients and can be deduced from the general formula but since the function is anti-symmetric the constant part and all the cosine terms vanish, i.e. a0 = 0 and all an = 0.
2 2 2T 1π π
ω = = = π
10 n n2
n 1 n 1
f(t) a a cos(2 nt) b sin(2 nt)∞ ∞
= =
= + π + π∑ ∑
Revision of Fourier Series 22
Example 3Since the function is defined over the period the Fourier integrals can be done over that interval;
1 12 2t− ≤ ≤
( )( )
2
2 2
2
12 1
21 1n 2 n(2 n) 1
212
1 1 1 14 n 4 n(2 n) (2 n)
n2(2 n)
b 2 t sin(2 nt)dt 2 sin(2 nt) t cos(2 nt)
2 sin(n ) cos(n ) sin( n ) cos( n )
2 ( 1)
ππ −−
π ππ π
−π
⎛ ⎞⎡ ⎤= π = π − π⎜ ⎟⎢ ⎥⎜ ⎟⎣ ⎦⎝ ⎠
⎡ ⎤ ⎡ ⎤= π − π − − π + − π⎢ ⎥ ⎢ ⎥⎣ ⎦ ⎣ ⎦
= −
∫
2n 11
n ( n)b ( 1) +
π= −So
We could evaluate similar integrals for a0 and an , but the fact that f(t) is odd guarantees that a0 = an = 0.
Revision of Fourier Series 23
Example 3The Fourier series for this function is therefore:
( )21 1 1 1
4 9 16f(t) sin(2 t) sin(4 t) sin(6 t) sin(8 t)π
= π − π + π − π +L
1.5 1 0.5 0 0.5 1 1.5
0.5
0.5
1.5 1 0.5 0 0.5 1 1.5
0.5
0.5
Fundamental only
1st and 2nd harmonics
1.5 1 0.5 0 0.5 1 1.5
0.5
0.5
1.5 1 0.5 0 0.5 1 1.5
0.5
0.5
1st - 4th harmonics
1st - 16th harmonics
Revision of Fourier Series 24
Half-Range SeriesA non-periodic function f(t) may be associated with three different Fourier series. Each of these will match the function over the region , but will also repeat the same function profile periodically.
The first is the normal Full-Range Fourier Series already discussed.The second is formed by making an even extension of the function – the Half-Range Cosine Series.The third is formed by making an odd extension of the function – the Half-Range Sine Series.
Revision of Fourier Series 25
For f(t) defined over 0 < t < L, the half-range cosine series has period 2L and is given by
where
and
The Half-range Cosine series of a function defined over a region is an even or symmetric extension with period 2L
Half-Range Cosine Series
( )( )0 ntn L
n 1
aC(t) a cos2
∞π
=
= +∑C(t) f(t) over 0 t L
C( t) C(t), (symmetry)C(t 2L) C(t), (periodicity)
= < <⎧⎪ − =⎨⎪ + =⎩
( )L L
nt2 20 nL L L
0 0
a f(t)dt and a f(t)cos dtπ= =∫ ∫
Revision of Fourier Series 26
Half-Range Cosine Series
t
f(t)
L0
Half-range cosine series of f(t)
4L
C(t)
tL 2L 3L0–L
Revision of Fourier Series 27
For f(t) defined over 0 < t < L, the half-range sine series has period 2L and is given by
where
and
The Half-range Sine series of a function defined over a region is an odd or antisymmetric extension with period 2L
Half-Range Sine Series
( )( )ntn L
n 1
S(t) b sin∞
π
=
= ∑S(t) f(t) over 0 t L
S( t) S(t), (symmetry)S(t 2L) S(t), (periodicity)
= < <⎧⎪ − = −⎨⎪ + =⎩
( )L
nt2n L L
0
b f(t)sin dtπ= ∫
Revision of Fourier Series 28
Half-Range Sine Series
t
f(t)
L0
Half-range sine series of f(t)
4L
S(t)
tL 2L 3L0–L
Revision of Fourier Series 29
Example 4Obtain the half-range cosine and half-range sine series for
defined over 0 < t < 1.
The half-range cosine series will have period T = 2, (since L = 1) and has the form
2f(t) 1 t= −
( )( )10 n2
n 1
C(t) a a cos n t∞
=
= + π∑
Revision of Fourier Series 30
Example 4Using the general formula
and
[ ]1
12 32 1 1 40 1 3 3 30
0
a (1 t )dt 2 t t 2 1 0⎡ ⎤ ⎡ ⎤= − = − = − − =⎣ ⎦⎣ ⎦∫
( )
( ) ( ) ( ) ( ) ( ) ( ) ( )( )( ) ( ) ( ) ( ) ( ) ( ) ( )( ) [ ]
( )2 2
122
n 10
12 321 1 1 1n n n n
0
2 31 1 1 1n n n n
n4 4( n) ( n)
a (1 t )cos n t dt
2 sin n t t sin n t 2 tcos n t 2 sin n t
2 sin n sin n 2 cos n 2 sin n 0
cos n ( 1)
π π π π
π π π π
− −π π
= − π
⎡ ⎤= π − π + π − π⎢ ⎥⎣ ⎦
⎡ ⎤= π − π + π − π −⎢ ⎥⎣ ⎦= π = −
∫
Revision of Fourier Series 31
Example 4So
( ) ( ) ( )( )2
1 14 92 4
3 116
cos t cos 2 t cos 3 tC(t)
cos 4 t ... π
⎛ ⎞π − π + π⎜ ⎟= +⎜ ⎟− π +⎝ ⎠
Revision of Fourier Series 32
Example 4The half-range sine series will also have period T = 2, and takes the form
( )( )nn 1
S(t) b sin n t∞
=
= π∑
Revision of Fourier Series 33
Example 4( )
( ) ( ) ( ) ( ) ( ) ( ) ( )( )( ) ( ) ( ) ( ) ( ) ( ) ( )( )
122
n 10
12 321 1 1 1n n n n
0
2 31 1 1 1n n n n
1n
b (1 t )sin n t dt
2 cos n t t cos n t 2 t sin n t 2 cos n t
2 cos n cos n 2 sin n 2 cos n
2
π π π π
π π π π
π
= − π
⎡ ⎤= − π − − π + π + π⎢ ⎥⎣ ⎦
⎡ ⎤= − π − − π + π + π⎢ ⎥⎣ ⎦
− − − −
∫
( )( )( )( )3
31n
4 2n( n)
0 0 2
1 cos n
π
ππ
⎡ ⎤+ +⎢ ⎥⎣ ⎦
= − π +
So 3
2n
82nn ( n)
, n evenb , n odd
π
π π
⎧⎪= ⎨ +⎪⎩
Revision of Fourier Series 34
Example 4
( )( )( )
3
3
3
82 1
82 13 427
825 125
S(t) sin( t) sin(2 t)
sin(3 t) sin(4 t)
sin(5 t) ...
π ππ
π ππ
π π
= + π + π
+ + π + π
+ + π +
Revision of Fourier Series 35
Example 4
2 1 0 1 2 3 4
1
2 1 0 1 2 3 4
Cosine series, (up to 32nd harmonics)
Sine series, (up to 32nd harmonics)
1 0 1 2
1
f t( ) 1 t2
0 t< 1<
Revision of Fourier Series 36
Example 5Obtain the half-range sine series for a function
defined on the interval 0 < t < π.
The half-range sine series will have period T = 2π, and is given by
212 2
1 0 tf(t)
t
π
π
⎧ < <⎪= ⎨ < < π⎪⎩
( )( )nn 1
S(t) b sin nt∞
=
= ∑
Revision of Fourier Series 37
Example 5
( )
2n
0
22 2 1
20
2
2 1 2 12n 2n0 2
n n2 1 2 1 2 1 2 1n 2 n 2n 2n 2
n1 2 1n 2 n n
3n
b f(t) sin(nt) dt
sin(nt) dt sin(nt) dt
cos(nt) cos(nt)
cos( ) cos(n ) cos( )
cos( ) cos(n )
if
π
π
ππ
π ππ
π π
ππ π
π ππ π π π
ππ π π
π
=
= +
⎡ ⎤ ⎡ ⎤= − + −⎣ ⎦ ⎣ ⎦
⎡ ⎤ ⎡ ⎤⎡ ⎤ ⎡ ⎤= − − − + − π − −⎣ ⎦ ⎣ ⎦⎣ ⎦ ⎣ ⎦= − + − π
=
∫
∫ ∫
2n
n is odd n 2,6,10,...0 n 4,8,12,...
π
⎧⎪ =⎨⎪ =⎩