Professional Documents
Culture Documents
06 D Fourier Transform C
06 D Fourier Transform C
06 D Fourier Transform C
2 / 66
Outline
3 / 66
Outline
4 / 66
How do you like our lecture?
https://k10777.evasys.de/evasys/online.php?pswd=TUE16
5 / 66
Review
6 / 66
Review: Z-transforms of oscillations
Unfortunately, the Z-transforms of frequently used standard
signals are not particularly handy:
z
e jωnT · σn
n
❞ t |z| > 1
z − e jωT
z sin(ωT )
sin(ωnT ) · σn n
❞ t
2
|z| > 1
z − 2z cos(ωT ) + 1
z 2 − z cos(ωT )
cos(ωnT ) · σn ❞ t |z| > 1
n z 2 − 2z cos(ωT ) + 1
7 / 66
Review: Z-transforms of oscillations
Unfortunately, the Z-transforms of frequently used standard
signals are not particularly handy:
z
e jωnT · σn
n
❞ t |z| > 1
z − e jωT
z sin(ωT )
sin(ωnT ) · σn n
❞ t
2
|z| > 1
z − 2z cos(ωT ) + 1
z 2 − z cos(ωT )
cos(ωnT ) · σn ❞ t |z| > 1
n z 2 − 2z cos(ωT ) + 1
7 / 66
Review: Pseudo-continuous signal
xs (t)
0 1 2 t
8 / 66
Review: Fourier transform of sampled signal
(using the convolution theorem in step 3). From this it was easy to
see that a discrete signal has a periodic spectrum.
9 / 66
Review: Fourier transform of sampled signal
(using the convolution theorem in step 3). From this it was easy to
see that a discrete signal has a periodic spectrum.
A drawback of this form is that knowledge of the complete
continuous-time signal x(t) is required – or at least its spectrum.
In practice, only samples xn of the signal are known.
9 / 66
Fourier transform of sampled signal
As an alternative, the Fourier transform of the sampled signal can be
calculated directly, without using the convolution theorem:
Xs (jω) =
Fourier transform of sampled signal
As an alternative, the Fourier transform of the sampled signal can be
calculated directly, without using the convolution theorem:
Z ∞
Xs (jω) = F xs (t) = e −jωt xs (t) dt
−∞
Z ∞ ∞
X
= e −jωt x (t) δ(t − nTs ) dt
−∞ n=−∞
∞ Z
X ∞ ∞
X
= e −jωt x (t) δ(t − nTs ) dt = e −jωnTs xn .
n=−∞ −∞ n=−∞
discrete-time
Z-transform
Fourier transform
∞
X ∞
X (z) = z −n xn z→e jωTs
X
−→ Xs (jω) = e −jωnTs xn
k=0
n=−∞
11 / 66
Outline
12 / 66
∞
X ∞
X −n
Xs (jω) = e −jωnTs
xn = e jωTs xn
n=−∞ n=−∞
13 / 66
Definition (discrete-time Fourier transform DTFT)
The mapping
∞
X
e −jΩn xn = X (jΩ)
F : (xn )n∈Z 7−→ F (xn )n∈Z =
n=−∞
(xn )n ❝ s X (jΩ).
14 / 66
Definition (discrete-time Fourier transform DTFT)
The mapping
∞
X
e −jΩn xn = X (jΩ)
F : (xn )n∈Z 7−→ F (xn )n∈Z =
n=−∞
(xn )n ❝ s X (jΩ).
14 / 66
DTFT: unit impulse (δn )n Proof
(δn )n ❞ t 1
15 / 66
DTFT: constant signal (1)n Proof
16 / 66
Index-shifting Proof
17 / 66
DTFT: causal exponential signal (σn an )n Proof
e jΩ
(σn a n )n ❞ t
e jΩ −a
|a| < 1
18 / 66
DTFT: complex oscillation (e jΩ0 n )n Proof
(e jΩ0 n )n ❞ t 2π X2π (Ω − Ω0 )
19 / 66
DTFT: real oscillations sin(Ω0n) n
and cos(Ω0n) n
Proof
π
sin(Ω0 n) n
❞ t
j
· X2π (Ω − Ω0 ) − X2π (Ω + Ω0 )
cos(Ω0 n) n
❞ t π · X2π (Ω − Ω0 ) + X2π (Ω + Ω0 )
20 / 66
◮ In accordance with the duality principle:
21 / 66
◮ In accordance with the duality principle:
21 / 66
◮ In accordance with the duality principle:
21 / 66
◮ In accordance with the duality principle:
21 / 66
The inverse discrete-time Fourier transform can be defined
straight-forward:
22 / 66
Inverse discrete-time Fourier transform
Applying the inverse DTFT to a spectrum yields the original signal:
F −1 F ((xn )n ) =
Inverse discrete-time Fourier transform
Applying the inverse DTFT to a spectrum yields the original signal:
Z π
−1
−1
1 jΩn
F F ((xn )n ) = F X (jΩ) = e X (jΩ) dΩ
2π −π n∈Z
∞
!
1
Z π X
= e jΩn e −jΩk xk dΩ
2π −π
k=−∞ n∈Z
∞
!
1
Z π
(∗) X
= xk · e jΩ·(n−k)dΩ
2π −π
k=−∞ n∈Z
∞
!
X
= xk δn−k = (xn )n∈Z .
k=−∞ n∈Z
(∗)
In the step marked with ,
1 π
Z
e jΩ·(n−k)dΩ = δn−k
2π −π
Proof:
24 / 66
1 π
Z
e jΩ·(n−k)dΩ = δn−k
2π −π
Proof:
Case n = k
1 1 1 1
Z π Z π Z π
e jΩ·(n−k) dΩ = e jΩ·0 dΩ = dΩ = · 2π = 1.
2π −π 2π −π 2π −π 2π
Case n 6= k ⇒ n − k = m ∈ Z
jΩm π
1 π
1 1 e jπm − e −jπm 2j sin(πm)
Z
jΩm e
e dΩ = · = · = · = 0.
2π −π 2π jm −π 2π jm 2π jm
24 / 66
Convolution Proof
25 / 66
, The discrete-time Fourier transform corresponds to the known
continuous-time Fourier transform in all relevant aspects.
26 / 66
, The discrete-time Fourier transform corresponds to the known
continuous-time Fourier transform in all relevant aspects.
26 / 66
, The discrete-time Fourier transform corresponds to the known
continuous-time Fourier transform in all relevant aspects.
26 / 66
, The discrete-time Fourier transform corresponds to the known
continuous-time Fourier transform in all relevant aspects.
26 / 66
Outline
27 / 66
Discrete spectrum
Signals that are periodic in the time domain have discrete (in
other words: sampled) spectra.
(xn )n=0,1,2,...,N−1.
28 / 66
X4,n
2
1 b b b b b
0 b b b b b b b b b b b b b
n
−1
−9 −8 −7 −6 −5 −4 −3 −2 −1 0 1 2 3 4 5 6 7 8 9
2π
(XN,n )n ❝ s
N X 2π (Ω) Proof
N
29 / 66
Periodically repeated signal
30 / 66
Fourier transform of a periodically repeated signal
The Fourier transform of the periodically repeated signal (x̃n )n
can then be determined using the convolution theorem:
31 / 66
Fourier transform of periodic signal
∞
X 2π 2π 2π
(x̃n )n ❝ s X̃ (jΩ) = XN (j k) · · δ(Ω − k)
N N N
k=−∞
32 / 66
Fourier transform of periodic signal
∞
X 2π 2π 2π
(x̃n )n ❝ s X̃ (jΩ) = XN (j k) · · δ(Ω − k)
N N N
k=−∞
32 / 66
Fourier transform of periodic signal
∞
X 2π 2π 2π
(x̃n )n ❝ s X̃ (jΩ) = XN (j k) · · δ(Ω − k)
N N N
k=−∞
32 / 66
Fourier transform of periodic signal
∞
X 2π 2π 2π
(x̃n )n ❝ s X̃ (jΩ) = XN (j k) · · δ(Ω − k)
N N N
k=−∞
32 / 66
Definition (discrete Fourier transform DFT)
The mapping
N−1
!
2π
X
nk
e −j
F : (xn )n 7−→ F (xn )n = N xk = (Xn )n ,
k=0 n
which for N ∈ N and n = 0, . . . , N − 1 maps a discrete signal
(xn )n to the discrete complex spectrum (Xn )n is called discrete
Fourier transform (DFT).
33 / 66
Discrete Fourier transform DFT
N−1
!
−j 2π
X
nk
(Xn )n = e N xk for n = 0, . . . , N − 1
k=0 n
34 / 66
Discrete Fourier transform DFT
N−1
!
−j 2π
X
nk
(Xn )n = e N xk for n = 0, . . . , N − 1
k=0 n
34 / 66
Discrete Fourier transform DFT
N−1
!
−j 2π
X
nk
(Xn )n = e N xk for n = 0, . . . , N − 1
k=0 n
34 / 66
Definition (complex rotation factor)
The expression
2π
WN = e −j N
35 / 66
Definition (complex rotation factor)
The expression
2π
WN = e −j N
k=0 k=0
35 / 66
Discrete Fourier transform and its inverse
This equation can be inverted and solved for the nth element
of the discrete signal
N−1
1 X −kn
xn = WN Xk . Proof
N
k=0
36 / 66
Definition (inverse discrete Fourier transform)
The mapping
N−1
!
1 X 2π
F −1 : (Xn )n 7−→ F −1 (Xn )n = e j N nk Xk
= (xn )n ,
N
k=0 n
which for N ∈ N and n = 0, . . . , N − 1 maps a discrete
spectrum (Xn )n to the discrete signal (xn )n is called inverse
discrete Fourier transform.
37 / 66
Properties of the DFT
The following properties of the DFT are only listed here. All of
them are either clear from the definition or can be proved by
shifting indices, reversing the order of summation and / or
using the periodicity of both signal and spectrum.
38 / 66
Properties of the DFT
linearity: (a x n )n + (b x n )n ❝ s a (Xn )n + b (Yn )n
time-mirroring: (xN−n )n ❝ s (X
N−n )n
complex conjugation: (x ∗ n )n ❝ s (X ∗
N−n )n
1 ∗
real part: ℜ(xn ) n ❝ s · (Xn + XN−n )n
2
s 1 · (Xn − X ∗ )n
imaginary part: ℑ(xn ) n ❝
N−n
2j
periodic convolution: (xn )n ⊗ (yn )n ❝ s (Xn )n · (Yn )n
1
multiplication: (xn · yn )n ❝ · (Xn )n ⊗ (Yn )n
s
N
(An example for the convolution will be presented later to explain
the meaning of the special symbol ⊗.)
39 / 66
DFT of selected signals Proof
constant: (1)n ❝ s (N δ )
n n
2π
exponential: (e j N ·n0 n )n ❝ s (N δ
(n−n0 )modN )n
n0 N
sine: sin(2π n) n ❝ s · (δ(n−n0 )modN − δ(n+n0 )modN ) n
N 2j
n0 N
cosine: cos(2π n) n ❝ s · (δ(n−n0 )modN + δ(n+n0 )modN ) n
N 2
40 / 66
Practical implementation of DFT
Since both the signal and its spectrum consist of only N samples,
the discrete Fourier transform
N−1
X
Xn = WNnk xk
k=0
41 / 66
Inverse matrix
(the elements of the inverted matrix simply are reciprocals of the original
matrix).
42 / 66
Examples with N = 4
43 / 66
Example 1 xn
4
3 b b
2
1 b b
0
−1 0 1 2 3 4n
(xn )n =
44 / 66
Example 1 xn
4
3 b b
2
1 b b
0
−1 0 1 2 3 4n
(xn )n =
44 / 66
Example 1 xn x (t)
4
3 b b
2
1 b b
t
0
−1 0 1 2 3 4n
45 / 66
Example 2
1 j −1 −j 0
Example 2
1 j −1 −j 0 j
46 / 66
Example 2
Inverse discrete Fourier transforming (Xn )2n = (9, −1, 1, −1) yields
1 1 1 1 9
1 1 j −1 −j −1
(xn )n = · · =
4 1 −1 1 −1 1
1 −j −1 j −1
Example 2
Inverse discrete Fourier transforming (Xn )2n = (9, −1, 1, −1) yields
1 1 1 1 9 2
1 1 j −1 −j −1 2
(xn )n = · · = ,
4 1 −1 1 −1 1 3
1 −j −1 j −1 2
Because the fifth entry has no space in the N = 4 signal, the DFT
adds it to the first entry, resulting into
xn = (1 + 1, 2, 3, 2) = (2, 2, 3, 2).
data volume 1 kB 1 MB 1 GB
N2 0.6 ms 10.4 min 20 years
N · log2 N 20 µs 45 ms 1.2 min
Computation time for a 100 Mflops computer
48 / 66
Example: FFT
49 / 66
Butterfly graphs
50 / 66
Butterfly graph for N = 16
52 / 66
What you should remember from this lecture ...
◮ discrete-time Fourier transform (DTFT)
– definition (incl. inverse)
– for signals
(δn )n , (1)n , (σn a−n )n , (e jΩ0 n )n , (sin(Ω0 n))n , (cos(Ω0 n))n
– convolution theorem
◮ discrete Fourier transform (DFT)
– definition (incl. inverse)
– complex rotation factor
– general properties and DFT of selected signals
– problems connected to finite-length convolution
– zero-padding
◮ general idea of Fast Fourier Transform (FFT) algorithm
54 / 66
DTFT: unit impulse (δn )n back
(δn )n ❞ t 1
Proof:
∞
X
F (δn )n = e −jΩn δn = e −jΩ0 = 1.
n=−∞
55 / 66
DTFT: constant signal (1)n back
Proof:
∞
X ∞
X
−jΩn
F (1)n = e 1= e −jΩn
n=−∞ n=−∞
= 2π X2π (Ω).
In the last step, the formula
∞
X 2π
e −jωkT = · X 2π (ω)
T T
k=−∞
56 / 66
Index-shifting back
Proof:
∞
X ∞−m
X
F (xn−m )n = e −jΩn xn−m = e −jΩ·(n+m) xn
n=−∞ n=−∞−m
X∞ ∞
X
−jΩ·(n+m) −jΩm
= e xn = e e −jΩn xn
n=−∞ n=−∞
= e −jΩm · F (xn )n = e −jΩm · X (jΩ)
57 / 66
DTFT: causal exponential signal (σn an )n back
e jΩ
(σn an )n ❝ s
e jΩ −a |a| < 1
Proof:
∞ ∞
X X a n
F (σn an )n = e −jΩn σn an =
n=−∞ n=0
e jΩ
(∗) 1 e jΩ
= a = jΩ for |a| < 1.
1 − e jΩ e −a
(∗)
In the step marked with , the geometric series formula
∞
X 1
rn = for constant r ∈ C with |r | < 1
n=0
1−r
can be employed, but only for the case |a| < 1 which implies
a |a|
|r | = jΩ
= jΩ = |a| < 1.
e |e |
For |a| ≥ 1, the sum diverges and the discrete-time Fourier transform
does not exist. 58 / 66
DTFT: complex oscillation (e jΩ0 n )n back
(e jΩ0 n )n ❞ t 2π X2π (Ω − Ω0 )
Proof:
∞
X ∞
X
F (e jΩ0 n )n = e −jΩn e jΩ0 n = e −j(Ω−Ω0 )n = 2π X2π (Ω − Ω0 ).
n=−∞ n=−∞
59 / 66
DTFT: real oscillations sin(Ω0n) n
back
π
sin(Ω0 n) n
❞ t
j
· X2π (Ω − Ω0 ) − X2π (Ω + Ω0 )
Proof:
1
· (e jΩ0 n − e −jΩ0 n )n
F (sin(Ω0 n))n = F
2j
1
= · 2π X2π (Ω − Ω0 ) − 2π X2π (Ω + Ω0 )
2j
π
= · X2π (Ω − Ω0 ) + X2π (Ω + Ω0 ) .
j
60 / 66
DTFT: real oscillations cos(Ω0n) n
back
cos(Ω0 n) n
❞ t π · X2π (Ω − Ω0 ) + X2π (Ω + Ω0 )
Proof:
1
· (e jΩ0 n + e −jΩ0 n )n
F (cos(Ω0 n))n = F
2
1
= · 2π X2π (Ω − Ω0 ) + 2π X2π (Ω + Ω0 )
2
= π · X2π (Ω − Ω0 ) + X2π (Ω + Ω0 ) .
61 / 66
Convolution back
Proof:
1 π
Z
jΩn
−1
F X (jΩ)Y (jΩ) = e · X (jΩ) · Y (jΩ) dΩ
2π −π n∈Z
∞ ∞
!
π
1
Z X X
jΩn −jΩk −jΩl
= e e xk e yl dΩ
2π −π k=−∞ l=−∞ n∈Z
∞ ∞
!
1 π
X X Z
= xk yl · e jΩ·(n−k−l)dΩ
2π −π
k=−∞ l=−∞ n∈Z
∞ ∞
!
X X
= xk yl δn−k−l
k=−∞ l=−∞ n∈Z
∞
!
X
= xk yn−k = (xn ∗ yn )n∈Z
k=−∞ n∈Z
62 / 66
DTFT: Discrete impulse comb back
2π
(XN,n )n ❝ s
N X 2π
N
(Ω)
Proof:
∞
X ∞
X ∞
X
F (X N,n )n = e −jΩn X N,n = e −jΩn δn−kN
n=−∞ n=−∞ k=−∞
∞
X ∞
X ∞
X
= e −jΩn δn−kN = e −jΩkN
k=−∞ n=−∞ k=−∞
2π
= · X 2π (Ω),
N N
known from last semester’s lecture 9 was applied, which for ω = Ω and T = N reads
∞
X 2π
e −jΩkN = · X 2π (Ω).
n=−∞
N N
63 / 66
Complex rotation factor property back
N−1 N−1
X X
−j 2π N for n = 0
WNnk = e N
·nk
= N δn =
0 else
k=0 k=0
Proof:
Case n = 0:
N−1 N−1 N−1
2π
X X X
WN0 = e −j N ·0 = 1 = N.
k=0 k=0 k=0
Case n 6= 0:
64 / 66
Inverse discrete Fourier transform back
N−1
1 X −kn
xn = WN Xk
N
k=0
Proof:
N−1 N−1 N−1 N−1 N−1
1 X −kn 1 X −kn X km 1 X X k·(m−n)
WN Xk = WN WN xm = xm WN
N N m=0
N m=0
k=0 k=0 k=0
N−1
1 X 1
= xm N δm−n = · xn · N = xn .
N m=0
N
65 / 66
DFT of selected signals back
Proof δ impulse:
N−1
X 2π
N−1
X
F (δn )n = e −j N nk δk = WNnk δk = WN0 = 1.
k=0 k=0
Proof constant:
N−1
X 2π
N−1
X N−1
X
F (1)n = e −j N nk 1 = WNnk 1 = WNnk = Nδn .
k=0 k=0 k=0
2π N−1
X 2π 2π
N−1
X
F (e j N ·n0 n
)n = e −j N nk e j N ·n0 k = WNnk WN−n0 k
k=0 k=0
N−1
(n−n0 )·k
X
= WN = Nδ(n−n0 )modN .
k=0
Proof sine and cosine: take imaginary and real part of complex exponential.
66 / 66