4.1 Trigonometric Fourier Series

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

Lab 4-Trigonometric Fourier Series

4.1 Trigonometric Fourier Series:

A second form of Fourier series is introduced in this section. Suppose that a signal x(t) is defined in
the time interval t0 , t0  T  . Then x(t) , by using the trigonometric Fourier series, can be

expressed in time interval t0 , t0  T  as a sum of sinusoidal signals, namely, sines and cosines,
where each signal has frequency k0 rad/s.

The mathematical expression (equation 4.1) is


 

x(t)  a0   bk cos(k 0t)  ck sin(k0 t)


k 1 k 1

The coefficients a0 , b1 , b2 , . . ., c1 , c2 , . . . of the trigonometric Fourier series are computed by

Example:

The signal that will be expanded is the same signal used at the previous example. Thus, the
problem is to expand in trigonometric Fourier series the signal x(t)  et , 0  t  3.

First the trigonometric Fourier coefficients bn , cn and the dc component a0 are computed
according to equations 4.3, 4.4 and 4.2, respectively, for n  1, 2,..., 200 . Next, approximated x(t) is
according to the relationship (equation 4.5)
N N

x(t)  a0   bk cos(k 0t)  ck sin(k0 t)


k 1 k 1
Commands Results/Comments
T=3; Definition of t0  0,T  3, 0  2 T and of the
t0=0;
w=2*pi/T; signal x(t)
syms t
a0=(1/T)*int(x,t,t0,t0+T); Computation of trigonometric coefficients
for n=1:200
b(n)=(2/T)*int(x*cos(n*w*t),t,t0,t0+T); according to equations 4.2, 4.3 and 4.4.
end
for n=1:200
c(n)=(2/T)*int(x*sin(n*w*t),t,t0,t0+T);
end
k=1:200; The signal x(t) is approximated by equation
xx=a0+sum(b.*cos(k*w*t))+sum(c.*sin(k*w*t))
10.1 or more precisely from equation 4.5 with
N=200.
ezplot(xx, [t0 t0+T]); Graph of the approximate signal xx(t ) that was
title('Approximation with 201 terms')
computed by the terms of the trigonometric
Fourier series.

The approximation with 201 terms of the


original signal x(t) is very good.

In order to understand the importance of the number terms used for the approximation of the
original signal x(t) , the approximate signal xx(t) is constructed for different values of n .
Approximation with five terms ( n  1,..., 5 )

Commands Results/Comments
clear b c When the signal is approximated with 5 terms,
for n=1:5
b(n)=(2/T)*int(x*cos(n*w*t),t,t0,t0+T); it is pretty dissimilar to the original signal.
c(n)=(2/T)*int(x*sin(n*w*t),t,t0,t0+T);
end
k=1:5;
xx=a0+sum(b.*cos(k*w*t))+sum(c.*sin(k*w*t))
ezplot(xx, [t0 t0+T]);
title('Approximation with 6 terms')

Approximation with 20 terms ( n  1,..., 20 )


Commands Results/Comments
for n=1:20 The approximated signal xx(t ) is now

end
k=1:20; quite satisfactory.
xx=a0+sum(b.*cos(k*w*t))
+sum(c.*sin(k*w*t));
ezplot(xx, [t0 t0+T]);
title('Approximation with 21 terms')

Properties of Fourier Series:

Linearity
Time Shifting
Time Reversal
Tasks
Task 01: The periodic signal x(t) is defined in one period as x(t)  tet , 0  t  6 . Plot approximate
signal using 81 terms of trigonometric form of Fourier series.

Task 02: Plot the coefficients of the trigonometric Fourier series for the periodic signal that in one
period is defined by x(t)  et ,  3  t  3 .

Task 03: The periodic signal x(t) in a period is given by


1, 0  t  1
x(t)  
0, 1  t  2
Plot in one period the approximate signals using 41 and 201 term of the trigonometric Fourier
series. Furthermore, each time plot the complex exponential coefficients.

Task 04: The periodic signal x(t) in a period is given by


 1, 0  t 1
x(t)  
2  t, 1  t  2
Calculate the approximation percentage when the signal x(t) is approximated by 3, 5, 7, and 17
terms of the trigometric Fourier series. Furthermore, plot the signal in each case.

You might also like