ELEC-C5231 Lecture3 Fourier Part1
ELEC-C5231 Lecture3 Fourier Part1
Filip Elvander
Filter design
(Ch. 10)
March 3, 2025
0.
From last week: eigenfunctions of LTI systems
Recall, input complex exponential (α ∈ R and ω ∈ R):
x(n) = en(α+ jω) , n = . . . , −2, −1, 0, 1, 2, . . . ,
Then, for an LTI system T ,
∞
y(n) = T (x(n)) = x(n) ∑ h(k)e−k(α+ jω) .
k=−∞
Even simpler, let α = 0:
∞
y(n) = T (x(n)) = x(n)H(ω) , H(ω) = ∑ h(k)e−k jω .
k=−∞
p=1 p=1
March 3, 2025
0.
Today in a nutshell: linear algebra
T
Let x = x1 x2 . . . xN ∈ RN . We can interpret the numbers x1 , . . . , xN as
• eTk eℓ
= 0 if k ̸= ℓ and eTk ek
= 1 ⇒ orthogonal ⇒ linearly independent.
• N linearly independent vectors ⇐⇒ basis for RN .
• Orthogonality: we can get the coordinates by simple multiplication,
ek T x = x1 ek T e1 +x2 ek T e2 + . . . + xk ek T ek + . . . + xN ek T eN = xk .
| {z } | {z } | {z } | {z }
=0 =0 =1 =0
Let a1 , a2 , . . . , aN be some other orthogonal basis for RN . That means
∃c1 , . . . , cN ∈ R : x = c1 a1 + . . . + cN aN .
Again, we can get the coefficients ck easily:
aTk x
ak T x = x1 ak T a1 + . . . + xN ak T aN = ak T ak ck ⇒ ck =
aTk ak
Today, we will do the same thing, but for signal spaces instead of RN : find a
basis that we can represent the signal in, and find the coefficients.
March 3, 2025
0.
Spoiler alert
In linear algebra, for any invertible matrix A ∈ RN×N , the operation
b = A−1 x
March 3, 2025
0.
WARNING
• All lot of today’s material has to do with infinite series and integrals over
the real line.
• Questions about convergence are important: operations like
interchanging summation and integration are only valid sometimes.
• This lecture is an overview of the application of Fourier techniques to
signals, but mathematical details are left out.
• The book is a bit sloppy in this respect: for a more exact treatment, see
your course on Fourier analysis.
• The Fourier transform has many important symmetry properties: for
these, see the last section of Chapter 4.
March 3, 2025
0.
Four types of signals
1 1
0.8 0.8
0.6 0.6
0.4 0.4
0.2 0.2
0 0
-0.2 -0.2
-0.4 -0.4
-0.6 -0.6
-0.8 -0.8
-1 -1
0 2 4 6 8 10 0 2 4 6 8 10
t t
Continuous and periodic. Continuous and aperiodic.
5 5
4 4
3 3
2 2
1 1
0 0
-1 -1
-2 -2
-3 -3
-4 -4
-5 -5
0 5 10 15 20 0 5 10 15 20
n n
Discrete and periodic. Discrete and aperiodic.
March 3, 2025
0.
Four types of signals
1 1
0.8 0.8
0.6 0.6
0.4 0.4
0.2 0.2
0 0
-0.2 -0.2
-0.4 -0.4
-0.6 -0.6
-0.8 -0.8
-1 -1
0 2 4 6 8 10 0 2 4 6 8 10
t t
Continuous and periodic. Continuous and aperiodic.
5 5
4 4
3 3
2 2
1 1
0 0
-1 -1
-2 -2
-3 -3
-4 -4
-5 -5
0 5 10 15 20 0 5 10 15 20
n n
Discrete and periodic. Discrete and aperiodic.
March 3, 2025
0.
Sinusoids
Consider a continuous-time (complex) sinusoid xa (t) according to
xa (t) = ce j2πF0 t , t ∈ R.
March 3, 2025
0.
Sums of sinusoids
Let’s now say that xa (t) is a sum K sinusoids according to
K
xa (t) = ∑ ck e j2πF t
k
k=1
K K K
?
xa (t + Tp ) = ∑ ck e j2πF (t+T ) = ∑ ck e j2πF t e j2πF T
k p k k p
= xa (t) = ∑ ck e j2πF t .
k
The only way to get equality for all t is to have e j2πFk Tp = 1, i.e., Fk Tp ∈ Z (Z is
the set of integers) for k = 1, . . . , K.
Fk Fk Tp N
⇒ = = k , for some Nk , Nℓ ∈ Z
Fℓ Fℓ Tp Nℓ
• For an arbitrary set of sinusoids, the signal will not repeat itself.
• Example below: the period Tp of the ”slowest” sinusoid is superimposed
in all plots.
March 3, 2025
0.
Harmonic mixture
March 3, 2025
0.
Harmonically related sinusoids
We have shown that the only sums of sinusoids that are periodic, are those
that are harmonically related:
K
xa (t) = ∑ ck e j2πkF t ,
0
for some F0 .
k=1
March 3, 2025
0.
Two immediate questions
March 3, 2025
0.
Electrocardiogram
1000 1.2
ECG
800 1
600 0.8
400 0.6
200 0.4
0 0.2
-200 0
0 0.5 1 1.5 10 20 30 40 50 60 70
time (s) frequency (Hz)
March 3, 2025
0.
Electrocardiogram
1000 1.2
ECG
800 1
600 0.8
400 0.6
200 0.4
0 0.2
-200 0
0 0.5 1 1.5 10 20 30 40 50 60 70
time (s) frequency (Hz)
March 3, 2025
0.
Continuous-time periodic signals
Let xa (t) be a continuous-time periodic signal with period Tp . If the signal is
”nice” enough, then we can(!!) represent it as a Fourier series:
∞
xa (t) = ∑ ck e j2πkF0 t , F0 = 1/Tp .
k=−∞
What are the coefficients ck ? For ℓ ∈ Z(= {0, ±1, ±2, . . .}),
Z Tp Z Tp ∞ Z Tp ∞
xa (t)e− j2πℓF0 t dt = ∑ ck e j2πkF0 t e− j2πℓF0 t dt = ∑ ck e j2π(k−ℓ)F0 t dt
0 0 k=−∞ 0 k=−∞
∞ Z Tp
”nice”
= ck
∑ e j2π(k−ℓ)F0 t dt
k=−∞ 0
∞ Z Tp
”nice”
= ck
∑ e j2π(k−ℓ)F0 t dt = Tp cℓ .
k=−∞ |0 {z }
=Tp if k = ℓ, otherwise 0
Z Tp
1
⇒ ck = xa (t)e− j2πkF0 t dt , k = 0, ±1, ±2, . . .
Tp 0
March 3, 2025
0.
Continuous-time periodic signals
The set e j2πF0 kt | k ∈ Z are orthogonal functions on the interval [0, Tp ]:
Z Tp
(
Tp if k = ℓ
e j2πkF0 t e− j2πℓF0 t dt =
0 0 if k ̸= ℓ.
Recall from linear algebra that if u1 , u2 , . . . , uN form an orthonormal basis for
RN , then for any vector x ∈ RN ,
N
x= ∑ ck uk , where ck = uTk x.
k=1
1 0.025
| ck | 2
0.8
0.6 0.02
0.4
0.2 0.015
-0.2 0.01
-0.4
-0.6 0.005
-0.8
-1 0
0 2 4 6 8 10 -6 -4 -2 0 2 4 6
t F (Hz)
March 3, 2025
0.
Signal decomposition
n o
The set of pairs kF0 , |ck |2 | k ∈ Z is called the power spectrum of xa (t),
motivated by
Z Tp ∞
1
Parseval’s identity: |xa (t)|2 dt = ∑ |ck |2 ⇒ |ck |2 power at kF0 .
Tp 0 k=−∞
1 0.15
0.8
0.6
0.4
0.1
0.2
-0.2
0.05
-0.4
-0.6
-0.8
-1 0
0 1 2 3 4 5 6 7 -6 -4 -2 0 2 4 6
F (Hz)
March 3, 2025
0.
Signal decomposition
n o
The set of pairs kF0 , |ck |2 | k ∈ Z is called the power spectrum of xa (t),
motivated by
Z Tp ∞
1
Parseval’s identity: |xa (t)|2 dt = ∑ |ck |2 ⇒ |ck |2 power at kF0 .
Tp 0 k=−∞
1 0.15
0.8
0.6
0.4
0.1
0.2
-0.2
0.05
-0.4
-0.6
-0.8
-1 0
0 1 2 3 4 5 6 7 -6 -4 -2 0 2 4 6
F (Hz)
March 3, 2025
0.
Signal decomposition
n o
The set of pairs kF0 , |ck |2 | k ∈ Z is called the power spectrum of xa (t),
motivated by
Z Tp ∞
1
Parseval’s identity: |xa (t)|2 dt = ∑ |ck |2 ⇒ |ck |2 power at kF0 .
Tp 0 k=−∞
1 0.15
0.8
0.6
0.4
0.1
0.2
-0.2
0.05
-0.4
-0.6
-0.8
-1 0
0 1 2 3 4 5 6 7 -6 -4 -2 0 2 4 6
F (Hz)
March 3, 2025
0.
Signal decomposition
n o
The set of pairs kF0 , |ck |2 | k ∈ Z is called the power spectrum of xa (t),
motivated by
Z Tp ∞
1
Parseval’s identity: |xa (t)|2 dt = ∑ |ck |2 ⇒ |ck |2 power at kF0 .
Tp 0 k=−∞
1 0.15
0.8
0.6
0.4
0.1
0.2
-0.2
0.05
-0.4
-0.6
-0.8
-1 0
0 1 2 3 4 5 6 7 -6 -4 -2 0 2 4 6
F (Hz)
March 3, 2025
0.
Signal decomposition
n o
The set of pairs kF0 , |ck |2 | k ∈ Z is called the power spectrum of xa (t),
motivated by
Z Tp ∞
1
Parseval’s identity: |xa (t)|2 dt = ∑ |ck |2 ⇒ |ck |2 power at kF0 .
Tp 0 k=−∞
1 0.15
0.8
0.6
0.4
0.1
0.2
-0.2
0.05
-0.4
-0.6
-0.8
-1 0
0 1 2 3 4 5 6 7 -6 -4 -2 0 2 4 6
F (Hz)
March 3, 2025
0.
Summary continuous-time periodic signals
Z Tp
1
Analysis equation: ck = xa (t)e− j2πkF0 t dt
Tp 0
∞
Synthesis equation: xa (t) = ∑ ck e j2πkF0 t
k=−∞
Z Tp ∞
1
Parseval’s identity: |xa (t)|2 dt = ∑ |ck |2
Tp 0 k=−∞
1 0.025
| ck | 2
0.8
0.6 0.02
0.4
0.2 0.015
-0.2 0.01
-0.4
-0.6 0.005
-0.8
-1 0
0 2 4 6 8 10 -6 -4 -2 0 2 4 6
t F (Hz)
March 3, 2025
0.
Electrocardiogram
• The location of the different peaks are kF0 , k = 1, . . . , K ≈ 30.
• F0 = 1/Tp , where Tp is the period (heart rate).
• The height of each peak is |ck |2 .
• The relative ”strength” of the different harmonics determines the shape
of the ECG waveform.
1000 1.2
ECG
800 1
600 0.8
400 0.6
200 0.4
0 0.2
-200 0
0 0.5 1 1.5 10 20 30 40 50 60 70
time (s) frequency (Hz)
March 3, 2025
0.
Four types of signals
1 1
0.8 0.8
0.6 0.6
0.4 0.4
0.2 0.2
0 0
-0.2 -0.2
-0.4 -0.4
-0.6 -0.6
-0.8 -0.8
-1 -1
0 2 4 6 8 10 0 2 4 6 8 10
t t
Continuous and periodic. Continuous and aperiodic.
5 5
4 4
3 3
2 2
1 1
0 0
-1 -1
-2 -2
-3 -3
-4 -4
-5 -5
0 5 10 15 20 0 5 10 15 20
n n
Discrete and periodic. Discrete and aperiodic.
March 3, 2025
0.
Can aperiodic signals have frequency?
Let’s say that that our aperiodic signal xa (t) is zero outside some interval
[−Tp /2, Tp /2]. Then, we can create a periodic extension x p (t) by periodically
repeating xa (t):
x p (t) = xa (t mod Tp ).
0.5
-0.5
-1
March 3, 2025
0.
Periodic extension
Note that, as x p (t) ≡ xa (t) for t ∈ [−Tp /2, Tp /2] and xa (t) ≡ 0 for
t∈
/ [−Tp /2, Tp /2]
Z Tp /2 Z Tp /2
analysis 1 1
ck = x p (t)e− j2πkF0 t dt= xa (t)e− j2πkF0 t dt
Tp −Tp /2 Tp −Tp /2
1
Z ∞
= xa (t)e− j2πkF0 t dt.
Tp −∞
Now comes the hand-wavy part: let’s define a function Xa (F), for any F, as
Z ∞
Xa (F) = xa (t)e− j2πFt dt.
−∞
1
Then, we have ck = Tp Xa (kF0 ) ⇒ Tp ck = Xa (kF0 ) = Xa (k/Tp ),
∞ ∞
synthesis 1
x p (t) = ∑ ck e j2πkF0 t = ∑ Xa (k/Tp )e j2πk/Tp t
k=−∞ T
k=−∞ p
∞
= ∑ Xa (k∆F )e j2πk∆F t ∆F , ∆F = 1/Tp .
k=−∞
March 3, 2025
0.
Hand-wavy motivation (1/2)
− j2πkFt dt):
R∞
We have the following (with Xa (F) = −∞ xa (t)e
1. x p (t) ≡ xa (t) for t ∈ [−Tp /2, Tp /2].
2. x p (t) = ∑∞ j2πk∆F t ∆ , ∆ = 1/T .
k=−∞ Xa (k∆F )e F F p
By 2) we have a frequency representation for x p (t), but not for xa (t).
March 3, 2025
0.
Hand-wavy motivation (2/2)
But what happens with the left-hand side when ∆F → 0? In fact, this is
a Riemann sum! As ∆F → 0, this converges to the Riemann integral
∞ Z ∞
j2πk∆F t
lim ∑ Xa (k∆F )e ∆F = Xa (F)e j2πFt dF.
∆F →0 −∞
k=−∞
March 3, 2025
0.
Continuous-time aperiodic signals
For aperiodic functions, the Fourier series is replaced by the Fourier
transform:
Z ∞
Analysis equation: Xa (F) = xa (t)e− j2πFt dt (Fourier transform)
−∞
Z ∞
Synthesis equation: xa (t) = Xa (F)e j2πFt dF (inverse Fourier transform)
−∞
Z ∞ Z ∞
Parseval’s identity: |xa (t)|2 dt = |X(F)|2 dF
−∞ −∞
March 3, 2025
0.
Differences between periodic and aperiodic signals
Periodic
Z Tp
1
Analysis equation: ck = xa (t)e− j2πkF0 t dt
Tp 0
∞
Synthesis equation: xa (t) = ∑ ck e j2πkF0 t
k=−∞
Z Tp ∞
1
Parseval’s identity: |xa (t)|2 dt = ∑ |ck |2
Tp 0 k=−∞
Aperiodic
Z ∞
Analysis equation: Xa (F) = xa (t)e− j2πFt dt (Fourier transform)
−∞
Z ∞
Synthesis equation: xa (t) = Xa (F)e j2πFt dF (inverse Fourier transform)
−∞
Z ∞ Z ∞
Parseval’s identity: |xa (t)|2 dt = |X(F)|2 dF
−∞ −∞
March 3, 2025
0.
Energy spectrum
• In contrast to the periodic case, we now have an energy spectrum.
• The spectrum |Xa (F)|2 typically has support in intervals (not only in
points).
• Similar to the periodic case, we can interpret |X(F)|2 as describing how
energy is distributed over frequency.
1 0.14
|X(F)|2
0.8
0.12
0.6
0.4 0.1
0.2
0.08
0
0.06
-0.2
-0.4 0.04
-0.6
0.02
-0.8
-1 0
0 2 4 6 8 10 -8 -6 -4 -2 0 2 4 6 8
t F
Cont.-time aperiodic signal. Energy spectrum.
March 3, 2025
0.
Energy spectrum
• In contrast to the periodic case, we now have an energy spectrum.
• The spectrum |Xa (F)|2 typically has support in intervals (not only in
points).
• Similar to the periodic case, we can interpret |X(F)|2 as describing how
energy is distributed over frequency.
1 0.4
|X(F)|
0.8
0.35
0.6
0.3
0.4
0.25
0.2
0 0.2
-0.2
0.15
-0.4
0.1
-0.6
-0.8 0.05
-1 0
0 0.5 1 1.5 2 2.5 -8 -6 -4 -2 0 2 4 6 8
t F
March 3, 2025
0.
Energy spectrum
• In contrast to the periodic case, we now have an energy spectrum.
• The spectrum |Xa (F)|2 typically has support in intervals (not only in
points).
• Similar to the periodic case, we can interpret |X(F)|2 as describing how
energy is distributed over frequency.
1 0.4
|X(F)|
0.8
0.35
0.6
0.3
0.4
0.25
0.2
0 0.2
-0.2
0.15
-0.4
0.1
-0.6
-0.8 0.05
-1 0
0 0.5 1 1.5 2 2.5 -8 -6 -4 -2 0 2 4 6 8
t F
March 3, 2025
0.
Energy spectrum
• In contrast to the periodic case, we now have an energy spectrum.
• The spectrum |Xa (F)|2 typically has support in intervals (not only in
points).
• Similar to the periodic case, we can interpret |X(F)|2 as describing how
energy is distributed over frequency.
1 0.4
|X(F)|
0.8
0.35
0.6
0.3
0.4
0.25
0.2
0 0.2
-0.2
0.15
-0.4
0.1
-0.6
-0.8 0.05
-1 0
0 0.5 1 1.5 2 2.5 -8 -6 -4 -2 0 2 4 6 8
t F
March 3, 2025
0.
Energy spectrum
• In contrast to the periodic case, we now have an energy spectrum.
• The spectrum |Xa (F)|2 typically has support in intervals (not only in
points).
• Similar to the periodic case, we can interpret |X(F)|2 as describing how
energy is distributed over frequency.
1 0.4
|X(F)|
0.8
0.35
0.6
0.3
0.4
0.25
0.2
0 0.2
-0.2
0.15
-0.4
0.1
-0.6
-0.8 0.05
-1 0
0 0.5 1 1.5 2 2.5 -8 -6 -4 -2 0 2 4 6 8
t F
March 3, 2025
0.
Electroencephalography (EEG)
• An EEG signal is not periodic (it’s actually random, but that’s for a later
course).
• However, Fourier analysis is still useful for understanding the frequency
content of the signal.
• The spectrum allows for identifying different frequency components
(so-called brainwaves).
• This is used for diagnosis of deceases as well as for brain-computer
interfaces.
8 70
6 60
4
50
2
40
0
30
-2
20
-4
-6 10
-8 0
0 0.5 1 1.5 2 0 10 20 30 40 50 60
March 3, 2025
0.
Summary
March 3, 2025