2. Signal and Systems
Fourier Series representation of
Periodical signals.
References
• Oppenheim, A. Willsky, and H. Nawab, Signals and Systems, 2ª edición, 1997, Prentice Hall, ISBN # 0-13-814757-4.
• Hwei P. Hsu, “Signals and Systems”, 2nd Edition, McGrawHill Schaum Outlines, ISBN: 978-0-07-163473-1, 2011.
• Chaparro Luis, “Signal and Systems using Matlab”, Elsevier, Oxford UK, ISBN 978-0-12-374716-7 , 2011
3. Fourier Series
• The response of an LTI system to any input consisting of a linear combination
of basic signals is the same linear combination of the individual responses to
each of the basic signals. We have 2 options for analysis:
• Option 1 (convolution): These responses were all shifted versions of the unit
impulse response, leading to the convolution sum or integral.
• Option 2 (complex exponentials): the response of an LTI system to a
complex exponential also has a particularly simple form, which then provides
us with another convenient representation for LTI systems. The resulting
representations are known as the continuous-time and discrete-time
Fourier series and transform.
4. Fourier Series
• If the input to an LTI system is expressed as a linear combination of periodic
complex exponentials, the output can also be expressed in this form, with
coefficients that are related in a straightforward way to those of the input.
• The physical motivation for Fourier's work was the phenomenon of heat
propagation and diffusion. By 1807, Fourier had found series of harmonically
related sinusoids to be useful in representing the temperature distribution
through a body. In addition, he claimed that "any" periodic signal could be
represented by such a series.
Waves in the ocean
consist of the linear
combination of sinusoidal
waves with different spatial
periods or wavelengths.
5. Fourier Series-The response of LTI systems to complex exponentials
It is advantageous in the study of LTI systems to represent signals as linear
combinations of basic signals that possess the following two properties:
1. The set of basic signals can be used to construct a broad and useful
class of signals.
• 2. The response of an LTI system to each signal should be simple to
provide us with a representation for the response of the system to any signal
constructed as a linear combination of the basic signals.
6. Fourier Series-The response of LTI systems to complex exponentials
Very important for the study of LTI systems: the response of an LTI
system to a complex exponential input is the same complex exponential with
only a change in amplitude; that is:
where the complex amplitude factor H(s) or H( z) will in general be a function of
the complex variable s or z.
A signal for which the system output is a (possibly complex) constant times the
input is referred to as an eigenfunction of the system, and the amplitude factor
is referred to as the system's eigenvalue.
7. Fourier Series-The response of LTI systems to complex exponentials
For both continuous time and discrete time, if the input to an LTI system is
represented as a linear combination of complex exponentials, then the output
can also be represented as a linear combination of the same complex
exponential signals.
INPUT OUTPUT
8. Fourier series representation of continuous-time periodic signals
Periodic signal
Fundamental period
Basic periodic signals
harmonically related
complex exponentials
Linear combination of
harmonically related
complex exponentials
13. Fourier series representation of continuous-time periodic signals
Trigonometric Fourier Series: even and odd signals
If a periodic signal x(t) is even, then bk= 0 and its Fourier series contains only
cosine terms:
If a periodic signal x(t) is odd, then ak= 0 and its Fourier series contains only sine
terms:
15. Fourier series -Examples
Given x(t) find its Fourier Series terms: ao, an, bn.
𝑓 𝑥 =
𝜋2
3
+ 3 +
𝑛=1
∞
4
𝑛2 −1 𝑛
∗ cos(𝑛𝑥) +
𝑛=1
∞
2
𝑛
−1 𝑛+1
∗ sin(𝑛𝑥)
𝒇 𝒙 = 𝒙2 + 𝒙 + 3 , −𝜋 ≤ 𝑥 ≤ 𝜋
Plot[[//math:t^2+t+3//],FourierTrig
Series[[//math:t^2+t+3//],t,[//mat
h:1//]],{t,-pi,pi}]
For n=1
Plot[[//math:t^2+t+3//],FourierTrig
Series[[//math:t^2+t+3//],t,[//mat
h:5//]],{t,-pi,pi}]
For n=5
𝑨𝑷𝑶𝑹𝑻𝑬:
16. Fourier series -Examples
Given f(x) find its Fourier Series terms: ao, an, bn.
𝒇 𝒙 = 𝒙2 + 𝒙 + 3 , −𝜋 ≤ 𝑥 ≤ 𝜋
WOLFRAM
x^2+x+3 for x=-pi to pi Fourierseries[x^2+x+3,x,1] Fourierseries[x^2+x+3,x,5] Fourierseries[x^2+x+3,x,10]
17. Fourier Series-Exercises
Given f(t) find its Fourier Series terms: ao, an, bn.
(2/pi)*[[integrate (pi/2)*sin(n*2*x) from x=0 to pi/2]+ [integrate (pi-x)*sin(n*2*x)
from x=pi/2 to pi]]
(2/pi)*[[integrate (pi/2) from x=0 to pi/2]+ [integrate (pi-x) from x=pi/2 to pi]]
(2/pi)*[[integrate (pi/2)*cos(n*2*x) from x=0 to pi/2]+ [integrate (pi-x)*cos(n*2*x) from x=pi/2 to pi]]
3*pi/8+sum { [1/(2*pi*i^2)*((-1)^i-1)*cos(2*i*t)] + [ (1/(2*i))*sin(2*i*t)] }, i=1 to 10
18. Fourier Series-Exercises
Given f(t) find its Fourier Series terms: ao, an, bn.
3*pi/8+sum { [1/(2*pi*i^2)*((-1)^i-1)*cos(2*i*t)] + [ (1/(2*i))*sin(2*i*t)] }, i=1 to 10
22. Fourier Series-Exercises
syms t k P n;
assume(k,'Integer')
a = @(f,t,k,P) int(f*cos(k*pi*t/P),t,-P,P)/P;
b = @(f,t,k,P) int(f*sin(k*pi*t/P),t,-P,P)/P;
fs=@(f,t,n,P)
a(f,t,0,P)/2+symsum(a(f,t,k,P)*cos(k*pi*t/P)+b(f,t,k,P)*sin(k*pi*t/P),k,1,n);
%Funcion
f=pi/2*(heaviside(t)-heaviside(t-pi/2))+(heaviside(t-pi/2)-heaviside(t-pi))*(pi-t);
P=pi;
N=6; %términos del desarrollo en serie
pretty(fs(f,t,N,P))
hold on
ezplot(f,[-P P])
hg=ezplot(fs(f,t,N,P),[-P P]);
set(hg,'color','r')
set(gca,'XTick',-pi:pi/2:pi)
set(gca,'XTickLabel',{'-pi','-pi/2','0','pi/2','pi'})
set(gca,'YTick',0:pi/2:pi)
set(gca,'YTickLabel',{'0','pi/2','pi'})
hold off
grid on
xlabel('t')
ylabel('f(t)')
title('Serie de Fourier')
𝑨𝒑𝒐𝒓𝒕𝒆: 𝑫𝒂𝒏𝒊𝒆𝒍𝒂 𝑨𝒍𝒗𝒂𝒓𝒆𝒛
24. Fourier Series-Exercises
COEFICIENTES
clear , clf, clc, close all
syms x n
%f=input('ingrese las funciones entre corchetes []
separadas por espacios');
%p=input('ingrese los puntos en que estan evaluadas las
funciones entre corchetes [] separadas por espacios');
f=[3*pi/2];%funciones
p=[0 pi/2];%intervalos
f=sym(f);
a0=0;
for i=1:length(f)
a0=a0+int(f(i),'x',p(i),p(i+1));
end
disp('coeficiente A0:')
a0=(a0/pi);
pretty(a0)
an=0;
for i=1:length(f)
an=an+int(f(i)*cos(n*x),'x',p(i),p(i+1));
end
disp('coeficiente An:')
an=(an/pi)
an=subs(an,{cos(pi*n),sin(pi*n)},{(-1)^n,0});
pretty(an)
bn=0;
for i=1:length(f)
bn=bn+int(f(i)*sin(n*x),'x',p(i),p(i+1));
end
disp('coeficiente Bn:')
bn=(bn/pi);
bn=subs(bn,{cos(pi*n),sin(pi*n)},{(-1)^n,0});
pretty(bn)
𝑨𝒑𝒐𝒓𝒕𝒆: 𝑫𝒂𝒏𝒊𝒆𝒍𝒂 𝑨𝒍𝒗𝒂𝒓𝒆𝒛
25. 2/pi *( integrate (pi/2)(SIN(2kt)) from 0to pi /2+ integrate (pi-t)(sin(2kt)) from pi/2 to pi)
𝑎𝑛
𝑏𝑛
2/pi *( integrate (pi/2)(cos(2kt)) from 0to pi /2+ integrate (pi-t)(cos(2kt)) from pi/2 to pi)
𝑨𝑷𝑶𝑹𝑻𝑬: 𝑨𝑳𝑬𝑿 𝑺𝑶𝑻𝑶
27. Fourier Series-Exercises
Given f(t) find its Fourier Series terms: ao, an, bn.
(1/a)* ( integrate (b/a*x+b) dx from x=-a to 0 + integrate
(-b/a*x+b) dx from x=0 to a )
(1/a)* ( integrate (b/a*x+b)*cos(pi*n*x/a) dx from
x=-a to 0 + integrate (-b/a*x+b)*cos(pi*n*x/a) dx
from x=0 to a )
(1/a)* ( integrate (b/a*x+b)*sin(pi*n*x/a) dx from x=-
a to 0 + integrate (-b/a*x+b)*sin(pi*n*x/a) dx from
x=0 to a )
28. Fourier Series-Exercises
Given f(t) find its Fourier Series terms: ao, an, bn.
WOLFRAM 5/2+2*5*sum[((1-(-1)^n)/(pi^2*n^2))*cos(pi*n*t/pi),{n,1,5}]
B=5
-pi <A < pi ,
29.
30. CONVERGENCE OF THE FOURIER SERIES
According Fourier: any periodic signal could be represented by a Fourier
series. Although this is not quite true, it is true that Fourier series can be used
to represent an extremely large class of periodic signals.
In some cases, the analysis equation may diverge; that is, the value obtained
for some of the coefficients ak may be infinite.
Moreover, even if all of the coefficients of the Fourier Series are finite, when
these coefficients are substituted into the synthesis equation the resulting
infinite series may not converge to the original signal x(t).
31. DIRCHILET CONDITIONS
A set of conditions, developed by P. L. Dirichlet, guarantees that x(t) equals
its Fourier series representation, except at isolated values of t for which x(t) is
discontinuous. The Dirichlet conditions are as follows:
Condition 1. Over any period, x(t) must be absolutely integrable; that is
32. DIRCHILET CONDITIONS
A set of conditions, developed by P. L. Dirichlet, guarantees that x(t) equals
its Fourier series representation, except at isolated values of t for which x(t) is
discontinuous. The Dirichlet conditions are as follows:
Condition 2. there are no more than a finite number of maxima and minima
during any single period of the signal.
Condition 1: ok
Condition 2: violates the
second Dirichlet condition
33. DIRCHILET CONDITIONS
A set of conditions, developed by P. L. Dirichlet, guarantees that x(t) equals
its Fourier series representation, except at isolated values of t for which x(t) is
discontinuous. The Dirichlet conditions are as follows:
Condition 3. In any finite interval of time, there are only a finite number of
discontinuities. Furthermore, each of these discontinuities is finite.
Condition 1: ?
Condition 3: violates the
third Dirichlet condition
Condition 2: ?
34. Power Content of a Periodic Signal:
Parseval's identity (or Parseval's theorem) for the Fourier series.
35. Fourier Series-Exercises
Individual work:
1) Find the Analysis
equations
2) Find the sinthesys
equation
3) Plot the f(t) and
compare with the
fourier series, for n=2,
n=5, n=8
plot(2*sum[(1-(-
1)^n)/(pi*n)*sin(pi*n*t
/2),{n,1,5}],{t,0,10})
To plot some
segments of the
summation
36. Fourier Series- References
Fourier harmonics in LTSPICE: https://www.youtube.com/watch?v=93yJHKGV7bM
Interesting link with instructions how to understand the Fourier harmonics in LTPICE.