4. Jean Baptiste Joseph Fourier
• Fourier was born in Auxerre, France in 1768
• Most famous for his work “La Théorie
Analitique de la Chaleur” (“The Analytic
Theory of Heat” in English) published in 1822
• It’s one of the most important mathematical
theories in modern engineering
5. Idea
• Any function that periodically repeats itself can be
expressed as a sum of sines and cosines of different
frequencies each multiplied by a different coefficient – a
Fourier series
6. Idea
• Notice how we get closer and closer to the original function
as we add more and more frequencies
7. Introduction to the Fourier Transform
and the Frequency Domain
• The one-dimensional Fourier transform and its inverse
Fourier transform (continuous case)
Inverse Fourier transform:
• The two-dimensional Fourier transform and its inverse
Fourier transform (continuous case)
Inverse Fourier transform:
du
e
u
F
x
f ux
j
2
)
(
)
(
dy
dx
e
y
x
f
v
u
F vy
ux
j )
(
2
)
,
(
)
,
(
1
where
)
(
)
( 2
j
dx
e
x
f
u
F ux
j
dv
du
e
v
u
F
y
x
f vy
ux
j )
(
2
)
,
(
)
,
(
sin
cos j
e j
8. 1D Discrete Fourier Transform
• The one-dimensional Fourier transform and its inverse
• 1 Discrete Fourier transform (DFT)
• Inverse Fourier transform:
1
,...,
2
,
1
,
0
for
)
(
1
)
(
1
0
/
2
M
u
e
x
f
M
u
F
M
x
M
ux
j
1
,...,
2
,
1
,
0
for
)
(
)
(
1
0
/
2
M
x
e
u
F
x
f
M
u
M
ux
j
9. Other Representation of
Fourier Transform
• Since and the fact
then discrete Fourier transform can be redefined
• Frequency (time) domain: the domain (values of u) over which the
values of F(u) range; because u determines the frequency of the
components of the transform.
• Frequency (time) component: each of the M terms of F(u).
1
,...,
2
,
1
,
0
for
M
u
1
0
]
/
2
sin
/
2
)[cos
(
1
)
(
M
x
M
ux
j
M
ux
x
f
M
u
F
sin
cos j
e j
cos
)
cos(
10. 1D Fourier Transform
in Polar Coordinates
• F(u) can be expressed in polar coordinates:
• R(u): the real part of F(u)
• I(u): the imaginary part of F(u)
• Power spectrum:
)
(
)
(
)
(
)
( 2
2
2
u
I
u
R
u
F
u
P
F(u) = F(u) ejj(u)
where F(u) = R2
(u)+ I2
(u)
é
ë
ù
û
1
2
j(u) = tan-1 I(u)
R(u)
é
ë
ê
ù
û
ú
(magnitude or spectrum)
(phase angle or phase spectrum)
11. 2D Discrete Fourier
Transform
• The two-dimensional Fourier transform and its inverse
• 2D Discrete Fourier transform (DFT)
• Inverse Fourier transform:
u, v : the transform or frequency variables
x, y : the spatial or image variables
1
,...,
2
,
1
,
0
,
1
,...,
2
,
1
,
0
for
)
,
(
1
)
,
(
1
0
1
0
)
/
/
(
2
N
v
M
u
e
y
x
f
MN
v
u
F
M
x
N
y
N
vy
M
ux
j
1
,...,
2
,
1
,
0
,
1
,...,
2
,
1
,
0
for
)
,
(
)
,
(
1
0
1
0
)
/
/
(
2
N
y
M
x
e
v
u
F
y
x
f
M
u
N
v
N
vy
M
ux
j
12. 2D Fourier Transform
in Polar Coordinates
• We define the Fourier spectrum, phase angle, and power spectrum as
follows:
R(u,v): the real part of F(u,v)
I(u,v): the imaginary part of F(u,v)
spectrum)
(power
)
,
(
)
,
(
)
,
(
)
(
angle)
(phase
)
,
(
)
,
(
tan
)
,
(
spectrum)
(
)
,
(
)
,
(
)
,
(
2
2
2
1
2
1
2
2
v
u
I
v
u
R
v
u
F
u,v
P
v
u
R
v
u
I
v
u
v
u
I
v
u
R
v
u
F
13. Fourier Transform is Separable
• The 2D DFT F(u,v) can be obtained by
• taking the 1D DFT of every row of image f(x,y), F(u,y),
• taking the 1D DFT of every column of F(u,y)
f(x,y) F(u,y) F(u,v)
15. Some Basic Properties of
Fourier Transform
A
B
DFT
Rotation
Linear Combination
0.25A + 0.75B
16. Some Basic Properties of
Fourier Transform
DFT
Expanding the original image by a factor of n (n=2), filling the empty new
values with zeros, results in the same DFT.
18. Image Filtering
In Frequency Domain
To filter an image in the frequency domain:
1. Compute F(u,v) the DFT of the image
2. Multiply F(u,v) by a filter function H(u,v)
3. Compute the inverse DFT of the result
19. Smoothing
Frequency Domain Filters
• Smoothing is achieved in the frequency domain by dropping out the
high frequency components
• The basic model for filtering is:
G(u,v) = H(u,v)F(u,v)
• where F(u,v) is the Fourier transform of the image being filtered and
H(u,v) is the filter transform function
• Low pass filters – only pass the low frequencies, drop the high ones
20. Ideal Low Pass Filter (ILPF)
• Simply cut off all high frequency components that are a specified
distance D0 from the origin of the transform
• Changing the distance changes the behaviour of the filter
21. Ideal Low Pass Filter
• The transfer function for the ideal low pass filter can be given as:
• where D(u,v) is given as:
0
0
)
,
(
if
0
)
,
(
if
1
)
,
(
D
v
u
D
D
v
u
D
v
u
H
2
/
1
2
2
]
)
2
/
(
)
2
/
[(
)
,
( N
v
M
u
v
u
D
22. Ideal Low Pass Filter
• An image and it’s Fourier spectrum and a series of ideal low pass
filters of radius 5, 15, 30, 80 and 230 superimposed on top of it
23. Ideal Low Pass Filter
Original
image
ILPF with
radius 5
ILPF with
radius 30
ILPF with
radius 230
ILPF with
radius 80
ILPF with
radius 15
24. Butterworth
Lowpass Filters (BLPF)
• The transfer function of a Butterworth lowpass filter of order n with
cutoff frequency at distance D0 from the origin is defined as:
n
D
v
u
D
v
u
H 2
0 ]
/
)
,
(
[
1
1
)
,
(
31. Sharpening
in the Frequency Domain
• Edges and fine detail in images are associated with high frequency
components
• High pass filters – only pass the high frequencies, drop the low ones
• High pass frequencies are precisely the reverse of low pass filters, so:
Hhp(u, v) = 1 – Hlp(u, v)
32. Ideal High Pass Filters (IHPF)
• The ideal high pass filter is given as:
• where D0 is the cut off distance
0
0
)
,
(
if
1
)
,
(
if
0
)
,
(
D
v
u
D
D
v
u
D
v
u
H
33. Ideal High Pass Filters
IHPF with D0 = 15 HPF with D0 = 30 IHPF with D0 = 80
34. Butterworth
High Pass Filters (BHPF)
• The Butterworth high pass filter is given as:
• where n is the order and D0 is the cut off distance as before
n
v
u
D
D
v
u
H 2
0 )]
,
(
/
[
1
1
)
,
(
35. Butterworth High Pass Filters
BHPF of order 2
with D0 = 15
BHPF of order 2
with D0 = 80
BHPF of order 2
with D0 = 30
36. Gaussian High Pass Filters (GHPF)
• The Gaussian high pass filter is given as:
• where D0 is the cut off distance as before
2
0
2
2
/
)
,
(
1
)
,
( D
v
u
D
e
v
u
H
37. Gaussian High Pass Filters
GHPF with D0 = 15 GHPF with D0 = 80
GHPF with D0 = 30
39. Fast Fourier Transform
• The reason that Fourier based techniques have become so popular is
the development of the Fast Fourier Transform (FFT) algorithm
• Allows the Fourier transform to be carried out in a reasonable amount
of time
• Reduces the amount of time required to perform a Fourier transform
by a factor of 100 – 600 times!
42. • By using Fourier Transform , we loose the time information :
WHEN did a particular event take place ?
• Fourier Transform (FT) can not locate drift, trends, abrupt
changes, beginning and ends of events, etc.
• Calculating use complex numbers.
What’s wrong with Fourier?
43. Stationarity of Signal
• Stationary Signal
– Signals with frequency content unchanged in time
– All frequency components exist at all times
• Non-stationary Signal
– Frequency changes in time
– One example: the “Chirp Signal”
45. Chirp Signals
Frequency: 2 Hz to 20 Hz
0 0.5 1
-1
-0.8
-0.6
-0.4
-0.2
0
0.2
0.4
0.6
0.8
1
0 5 10 15 20 25
0
50
100
150
Time
Magnitude
Magnitude
Frequency (Hz)
0 0.5 1
-1
-0.8
-0.6
-0.4
-0.2
0
0.2
0.4
0.6
0.8
1
0 5 10 15 20 25
0
50
100
150
Time
Magnitude
Magnitude
Frequency (Hz)
Different in Time Domain
Frequency: 20 Hz to 2 Hz
Same in Frequency Domain
At what time the frequency components occur? FT can not tell!
46. Nothing More, Nothing Less
• FT Only Gives what Frequency Components Exist in the Signal
• The Time and Frequency Information can not be Seen at the Same
Time
• Time-frequency Representation of the Signal is Needed
Most of Transportation Signals are Non-stationary.
(We need to know whether and also when an incident was happened.)
ONE EARLIER SOLUTION: SHORT-TIME FOURIER TRANSFORM (STFT)
47. Short Time Fourier Analysis
• In order to analyze small section of a signal, Denis Gabor (1946),
developed a technique, based on the FT and using windowing : STFT
2
( , ) ( ) ( )
u j ut
f
t
STFT t u f t W t t e dt
48. STFT (or: Gabor Transform)
• A compromise between time-based and frequency-based views of a
signal.
• both time and frequency are represented in limited precision.
• The precision is determined by the size of the window.
• Once you choose a particular size for the time window - it will be
the same for all frequencies.
50. Drawbacks Of STFT
• Unchanged Window
• Dilemma of Resolution
– Narrow window -> poor frequency resolution
– Wide window -> poor time resolution
• Heisenberg Uncertainty Principle
– Cannot know what frequency exists at what time intervals
Via Narrow Window Via Wide Window
51. What’s wrong with STFT?
• Many signals require a more flexible approach - so we can
vary the window size to determine more accurately either
time or frequency.
52. Multiresolution Analysis (MRA)
• Wavelet Transform
– An alternative approach to the short time Fourier transform to
overcome the resolution problem
– Similar to STFT: signal is multiplied with a function
• Multiresolution Analysis
– Analyze the signal at different frequencies with different
resolutions
– Good time resolution and poor frequency resolution at high
frequencies
– Good frequency resolution and poor time resolution at low
frequencies
– More suitable for short duration of higher frequency; and longer
duration of lower frequency components
53. Fourier Transform
• Breaks down a signal into constituent sinusoids of different
frequencies (ω)
In other words: Transform the view of the signal from time-base to
frequency-base.
54. Continuous Wavelet
Transform (CWT)
• Breaks down a signal into constituent wavelets of different
locations (τ) and scale (S)
• Mother Wavelet
– A prototype for generating the other window functions
– All the used windows are its dilated or compressed and shifted
versions
dt
s
t
t
x
s
s
s x
x
*
1
,
,
CWT
Translation
(lokasi dari
wavelet)
Scale
Mother Wavelet
55. What is a Wavelet?
• A wavelet is a waveform of limited duration that has an average value
of zero
• Unlike sinusoids that theoretically extend from minus to plus infinity,
wavelets have a beginning and an end
57. Shifting and Scaling
• Shifting a wavelet simply means delaying (or hastening) its onset
• Scaling a wavelet simply means stretching (or compressing) it
High scale
Low scale
58. Scale
• Scale
– S>1: dilate the signal
– S<1: compress the signal
• Low Frequency -> High Scale -> Non-detailed Global View of
Signal -> Span Entire Signal
• High Frequency -> Low Scale -> Detailed View Last in Short
Time
• Only Limited Interval of Scales is Necessary
59. CWT Calculation
1. Take a wavelet and compare it to a
section at the start of the original
signal
2. Calculate a number, C, that
represents how closely correlated
the wavelet is with this section of
the signal
3. Shift the wavelet to the right and
repeat steps 1 and 2 until you’ve
covered the whole signal
4. Scale (stretch) the wavelet and
repeat steps 1 through 3
5. Repeat steps 1 through 4 for all
scales
Step 2
Step 3
Step 4
61. What’s
Continuous About the CWT?
• CWT can operate at every scale, from that of the original signal up to
some maximum scale that you determine by trading off your need for
detailed analysis with available computational horsepower
• The CWT is also continuous in terms of shifting: during computation,
the analyzing wavelet is shifted smoothly over the full domain of the
analyzed function
62. Discrete Wavelet Transform
(DWT)
• Calculating wavelet coefficients at every possible scale is a fair
amount of work, and it generates an awful lot of data
• What if we choose only a subset of scales and positions at which to
make our calculations?
• If we choose scales and positions based on powers of two — so-called
dyadic scales and positions — then our analysis will be much more
efficient and just as accurate
• An efficient way to implement this scheme using filters was
developed in 1988 by Mallat (two-channel subband coder) -> Fast
Discrete Wavelet Transform
64. Approximations and Details:
• Approximations: High-scale, low-frequency components of the signal
• Details: low-scale, high-frequency components
Input Signal
HPF
LPF
Details
Approximation
65. Decimation
• The former process produces twice the data it began with: N input
samples produce N approximations coefficients and N detail
coefficients.
• To correct this, we Down sample (or: Decimate) the filter output by
two, by simply throwing away every second coefficient.
Input
Signal
HPF
LPF
cD
cA
66. Multi-level Decomposition
• Iterating the decomposition process, breaks the input signal into
many lower-resolution components: Wavelet decomposition tree:
67. Wavelet reconstruction
• Reconstruction (or synthesis) is the process in which we
assemble all components back
Up sampling
(or interpolation) is done by zero inserting
between every two coefficients
Reconstructed
Signal
HPF’
LPF’
cD
cA
D
A
S=A+D
71. Acknowledgment
Some of slides in this PowerPoint presentation are adaptation from
various slides, many thanks to:
1. Dr. Brian Mac Namee, School of Computing at the Dublin Institute
of Technology (http://www.comp.dit.ie/bmacnamee/gaip.htm)
2. Hagit Hel-Or, Department of Computer Science University of Haifa,
Haifa 31905, Israel (http://cs.haifa.ac.il/hagit/)