Professional Documents
Culture Documents
Chapter 6
N
X −1
X[k] = x[n]e−j2πnk/N , 0 ≤ k ≤ N − 1 (6.1)
n=0
The original sequence x[n] can be obtained from the DFT representation X[k]
by the following
N −1
1 X
x[n] = X[k]ej2πnk/N , 0 ≤ n ≤ N − 1 ♦ (6.2)
N k=0
In these notes we will examine various properties pertaining to 6.1 and 6.2. An important
property is the fact that X[k] in 6.1 is periodic with period N , i.e.,
X[k + N ] = X[k] (6.3)
Also, in spite of the fact that x[n] is of finite duration, 0 ≤ n ≤ N − 1, we can still define
x[n] for values of n > N . As an example,
x[N + 1] = x[1] (6.4)
c
°A Course on Digital Signal Processing, Dr. Aly Farag, 2005
6-2 CHAPTER 6. THE DISCRETE FOURIER TRANSFORM
This issue of periodicity can be best studied through the point of view that x[n] is one period
of a periodic sequence x̃[n], and that X[k] is one period of a periodic sequence X̃[k]. For
example, figure 6.1 shows a finite sequence x[n] of length 5 and its periodic extension x̃[n].
x[n]
" "
#
$ $
% &
N =5
'
n
N −1
x̃[n]
0
1 (
)
. , ,
/
-
2 *
3
+
n
−N −(N − 1) −1 N −1N N +1 2N
Figure 6.1: A finite sequence x[n] and its periodic extension x̃[n].
Therefore, we will examine first the Fourier representation for periodic discrete sequences,
the Discrete Fourier series (DFS).
where r is an integer. We can represent x̃[n] in terms of the complex exponentials ej2πkn/N
as follows: ∞
1 X
x̃[n] = X̃[k]ej2πkn/N (6.6)
N k=−∞
c
°A Course on Digital Signal Processing, Dr. Aly Farag, 2005
6.1. THE DISCRETE FOURIER SERIES (DFS) 6-3
Theorem:
N
X −1
X̃[k] = x̃[n]e−j2πkn/N (6.9)
n=0
Proof :
Multiply both sides of 6.8 by e−j2πrn/N and perform the summation from n = 0
to N − 1, that is,
N
X −1 N −1 N −1
−j2πrn/N 1 XX
x̃[n]e = X̃[k]ej2π(k−r)n/N (6.10)
n=0
N n=0 k=0
N −1 N −1
( N −1
)
X X 1 X j2π(k−r)n/N
x̃[n]e−j2πrn/N = X̃[k] e (6.11)
n=0 k=0
N n=0
Now the term between the braces has a value of one if (k − r) is an integer
multiple of the period N , i.e.,
N −1 ½
1 X j2π(k−r)n/N 1, (k − r) = mN
e = (6.12)
N n=0 0, otherwise
c
°A Course on Digital Signal Processing, Dr. Aly Farag, 2005
6-4 CHAPTER 6. THE DISCRETE FOURIER TRANSFORM
N −1 ½
1 X j2π(k−r)n/N 1, k = r
e = (6.13)
N n=0 0, elsewhere
N
X −1 N
X −1
x̃[n]e−j2πrn/N = X̃[k] (6.14)
n=0 k=0,k=r
Therefore,
N
X −1
X̃[k] = x̃[n]e−j2πkn/N (6.15)
n=0
Q.E.D.
4
If we define the parameter WN = e−j2π/N , we can write 6.16 and 6.17, in terms of WN as:
N −1
1 X
x̃[n] = X̃[k]WN−kn (6.18)
N k=0
N
X −1
X̃[k] = x̃[n]WNkn (6.19)
n=0
Notes:
c
°A Course on Digital Signal Processing, Dr. Aly Farag, 2005
6.1. THE DISCRETE FOURIER SERIES (DFS) 6-5
Example 1:
∞
X
x̃[n] = δ[n + rN ] (6.20)
r=−∞
where
½
1, n = 0
δ[n] = (6.21)
0, otherwise
N
X −1
X̃[k] = x̃[n]e−j2πkn/N (6.22)
n=0
N
X −1
= δ[n]e−j2πkn/N (6.23)
n=0
¦¦¦
c
°A Course on Digital Signal Processing, Dr. Aly Farag, 2005
6-6 CHAPTER 6. THE DISCRETE FOURIER TRANSFORM
x̃[n]
:
;
n
0 N −1 N
X̃[k]
,
-
,
- ./ 01 4 23
6
4
5
6
7
1 89
*
+
&
'
(
)
&
'
<
=
$
%
"
# !
<
=
<
=
k
0 N −1 N
Example 2:
∞
X
x̃[n] = x[n + rN ] (6.25)
r=−∞
½
1, o ≤ n ≤ 4
where x[n] = (6.26)
0, else
and N = 10
N
X −1
X̃[k] = x̃[n]e−j2πkn/N , N = 10
n=0
X9 4
X
−j2πkn/10
= x̃[n]e = 1 e−j2πkn/10
n=0 n=0
−j2πk5/10
1−e sin(πk/2)
= −j2πk/10
= e−j2πk/10 (6.27)
1−e sin(πk/10)
¦¦¦
c
°A Course on Digital Signal Processing, Dr. Aly Farag, 2005
6.1. THE DISCRETE FOURIER SERIES (DFS) 6-7
x̃[n]
1
&
' () *+ ,- ./
f
g
h
i
f
g
d
e
b
c
`
a
"
!
$ "
#
$
%
r
s
p r
s
p
q
l
m
n
o
j
k
l
m
j
k
n
−10 0 1 2 3 4 10 11 12 13 14 \
|X̃[k]| J
K
F
G
6
7
6
7
2
3
X X
Y ]
H
I 5 4
5
Z Z
[ \
J F 6 6 2 X X
K G 7 7 3 Y ]
B > > : : 0 0 L L
C ? ; ; 1 1 M M U U V
D
E
@
@
A
<
<
=
8
9
R
S
N
O QP
T QP
T W
^
_
^
_
k
0 1 2 3 4 5 6 7 8 9 10
ang X̃[k]
π
t
u v
w x
} ~
~
k
{ |
y z
Relationship between the DFS representation X̃[k] and the sequence Fourier transform
X(ejfd ) over one period of the periodic sequence x̃[n]. Let x[n] represent one period of x̃[n],
i.e.,
½
x̃[n], 0 ≤ n ≤ N − 1
x[n] = (6.28)
0 otherwise
Illustration:
Now,
N
X −1
X(fd ) = x[n]e−j2πfd n (6.29)
n=0
N
X −1
≡ x̃[n]e−j2πfd n
n=0
c
°A Course on Digital Signal Processing, Dr. Aly Farag, 2005
6-8 CHAPTER 6. THE DISCRETE FOURIER TRANSFORM
2
3
2
3 4
0
1
0
1
x̃[n] $ $
%
. "
5 6 / #
,
7 - !
8 8 * *
9 9 : +
(
; < )
&
n
= '
0 1 2 N
x[n]
>
>
?
n
0 N
Figure 6.3:
Therefore,
N
X −1
X̃[k] = x[n]e−j2πkn/N (6.30)
n=0
This corresponds to sampling the sequence Fourier transform at N equally spaced frequen-
cies between fd = 0 and fd = 1 with a frequency spacing of N1 .
Example 3:
½
1, 0 ≤ n ≤ 4,
x[n] = (6.32)
0, otherwise
The Fourier transform of one period x̃[n] is given by
c
°A Course on Digital Signal Processing, Dr. Aly Farag, 2005
6.1. THE DISCRETE FOURIER SERIES (DFS) 6-9
4
X
X(fd ) = 1 e−j2πfd n (6.33)
n=0
sin(5πfd )
= e−j4πfd (6.34)
sin(πfd )
Recall:
From 6.34 the magnitude and phase for X(fd ) and X̃[k] can be plotted as in
figure 6.4.
c
°A Course on Digital Signal Processing, Dr. Aly Farag, 2005
6-10 CHAPTER 6. THE DISCRETE FOURIER TRANSFORM
' (
)
% &
<
# $
! "
<
1 3 fd
0 2
1 2
2
0 5 10 15 20 k
= = = = = = = = = = = =
> > > > > > > > > > > >
*
+
,
- .
fd
1 / 2
8 4
9 5
: 6
; 7 3
−π
Figure 6.4: Plots for Example 3 illustrating that the DFS coefficients of a periodic sequence
are samples of the sequence Fourier transform of one period.
¦¦¦
DF S
x̃1 [n] ←→ X̃1 [k] (6.36)
DF S
and x̃1 [n] ←→ X̃1 [k] (6.37)
DF S
Then ax̃1 [n] + bx̃2 [n] ←→ aX̃1 [k] + bX̃2 [k] (6.38)
c
°A Course on Digital Signal Processing, Dr. Aly Farag, 2005
6.2. PROPERTIES OF THE DISCRETE FOURIER SERIES (DFS) 6-11
a. Time Shift
DF S
If x̃[n] ←→ X̃[k] (6.39)
DF S
then x̃[n − m] ←→ e−j2πkm/N X̃[k] (6.40)
Proof :
N
X −1
4
DFS {x̃[n − m]} = x̃[n − m]e−j2πkn/N (6.41)
n=0
Let [n − m] = l,
then n|N −1
n=0 , l|N
−m
−1−m
, n=l+m (6.42)
N −1−m
X
DFS {x̃[n − m]} = x̃[n]e−j2πk(l+m)/N (6.43)
l=−m
N −1−m
X
−j2πkm/N
= e x̃[l]e−j2πkl/N (6.44)
l=−m
−j2πkm/N
≡ e X̃[k] (6.45)
Q.E.D.
b. Frequency Shift
DF S
If x̃[n] ←→ X̃[k] (6.46)
DF S
then ej2πnl/N x̃[n] ←→ X̃[k − l] (6.47)
Proof :
© j2πnl/N ª 4 N
X −1
DFS e x̃[n] = ej2πnl/N x̃[n]e−j2πkn/N (6.48)
n=0
N
X −1
= x̃[n]e−j2π(k−l)n/N (6.49)
n=0
≡ X̃[k − l] (6.50)
c
°A Course on Digital Signal Processing, Dr. Aly Farag, 2005
6-12 CHAPTER 6. THE DISCRETE FOURIER TRANSFORM
Q.E.D.
(iii) Duality of Discrete Fourier Series Coefficients
Recall that for a continuous-time signal x(t), the duality property of the Fourier transform
was stated as follows:
If x(t) ←→ X(f ) then (6.51)
X(t) ←→ x(−f ), f in Hz. (6.52)
Example 4:
T
1
t 0 f
− T2 T
2 1
− T1 T
T 1
t f
1 1
− 2T 2T
−2T −T T 2T 3T
N −1
4 1 X
x̃[n] = X̃[k]ej2πkn/N
N k=0
N −1
1 X
x̃[−n] = X̃[k]e−j2πkn/N
N k=0
N
X −1
N x̃[−n] = X̃[k]e−j2πkn/N
k=0
n o
4
= DFS X̃[k]
c
°A Course on Digital Signal Processing, Dr. Aly Farag, 2005
6.2. PROPERTIES OF THE DISCRETE FOURIER SERIES (DFS) 6-13
Hence,
DF S
If x̃[n] ←→ X̃[k] then (6.53)
DF S
X̃[n] ←→ N x̃[−k] (6.54)
¦¦¦
(iv) Symmetry Properties for the DFS
Consider a real sequence x̃[n], it is straight forward to prove the following properties:
a. X̃[k] = X̃[−k]
b. Re{X̃[k]} = Re{X̃[−k]}
c. Im{X̃[k]} = −Im{X̃[−k]}
d. |X̃[k]| = |X̃[−k]|
DF S
f. x̃e [n] = 21 (x̃[n] + x̃[−n]) ←→ Re{X̃[k]}
DF S
g. x̃o [n] = 21 (x̃[n] − x̃[n]) ←→ jIm{X̃[k]}
where xe [n] is an even sequence, xo [n] is an odd sequence, Re{ } denotes the real part and
Im{ } denotes the imaginary part.
Proof :
c
°A Course on Digital Signal Processing, Dr. Aly Farag, 2005
6-14 CHAPTER 6. THE DISCRETE FOURIER TRANSFORM
Consider the sequence x̃3 [n] defined as in 6.56. The DFS coefficients X̃3 [k] is
N
X −1
4
X̃3 [k] = x̃3 [n]e−j2πkn/N (6.57)
n=0
N
( −1
−1 N
)
X X
= x̃1 [m]x̃2 [n − m] e−j2πkn/N (6.58)
n=0 m=0
N
X −1 N
X −1
= x̃1 [m] x̃2 [n − m]e−j2πkn/N (6.59)
m=0 n=0
N
X −1
x̃2 [n − m]e−j2πkn/N = e−j2πkm/N X̃2 [k] (6.60)
n=0
Q.E.D.
In summary,
N
X −1
DF S
x̃1 [m]x̃2 [n − m] ←→ X̃1 [k]X̃2 [k] (6.62)
m=0
Periodic Convolution
Consider two periodic sequences x̃1 [n] and x̃2 [n] with the same period N . The periodic
convolution
N
X −1
x̃3 [n] = x̃1 [m]x̃2 [n − m] (6.63)
m=0
is calculated as follows:
c
°A Course on Digital Signal Processing, Dr. Aly Farag, 2005
6.2. PROPERTIES OF THE DISCRETE FOURIER SERIES (DFS) 6-15
1. Form the inverted sequence x̃2 [n − m] = x̃2 [−(m − n)] and the
product x̃1 [m]x̃2 [−(m − n)] for various values of n.
Note:
¦¦¦
Corollary:
From the duality theorem, if we exchange the roles of time and frequency, we
obtain an identical result to the periodic convolution, that is,
where x̃1 [n] and x̃2 [n] are periodic sequences each with period N , then the DFS
coefficients are given by
N −1
1 X
X̃3 [k] = X̃1 [l]X̃2 [k − l] (6.65)
N l=0
The proof of the above result is similar to the proof of periodic convolution in the time
domain we provided before. The reader should justify the above result. It is to be noted
that the convolution
N
X −1
X̃1 [l]X̃2 [k − l] (6.66)
l=0
c
°A Course on Digital Signal Processing, Dr. Aly Farag, 2005
6-16 CHAPTER 6. THE DISCRETE FOURIER TRANSFORM
x̃2 [m]
−N 0 N m
x̃1 [m]
m
−N 0 N
x̃2 [−m]
−N 0 N n
m
−N 0 N
x̃2 [2 − m] = x̃2 [−(m − 2)]
m
−N 0 N
Figure 6.6: Procedure for forming the periodic convolution of two periodic sequences.
2. x̃1 [n], x̃2 [n] X̃1 [k], X̃2 [k] periodic with period N
4. X̃[n] N x̃[−k]
1
PN −1
8. x̃1 [n]x̃2 [n] N l=0 X̃1 [l]X̃2 [k − l]
9. x̃[n] X̃[((−k))N ]
X̃[k] = X̃[−k]
Re{X̃[k]} = Re{X̃[−k]}
15. Symmetry properties Im{X̃[k]} = −Im{X̃[−k]}
(for real x[n])
|X̃[k]| = |X̃[−k]|
6
{X̃[k]} = −6 {X̃[−k]}
where r is an integer.
Therefore,
½
x̃[n], 0 ≤ n ≤ N − 1
x[n] = (6.68)
0, otherwise
Recall that
N −1
1 X
4
x̃[n] = X̃[k]ej2πkn/N (6.69)
N k=0
N
X −1
X̃[k] = x̃[n]e−j2πkn/N (6.70)
n=0
N
X −1
Analysis: X[k] = x[n]e−j2πkn/N , 0≤k ≤N −1 (6.72)
n=0
NX−1
1
Synthesis: x[n] = X[k]ej2πkn/N , 0≤n≤N −1 (6.73)
N k=0
DF T
x[n] ←→ X[k] (6.74)
c
°A Course on Digital Signal Processing, Dr. Aly Farag, 2005
6.4. PROPERTIES OF THE DFT 6-19
To see that x[n] is still defined for n > N , we substitute in 6.73 for values of n > N , i.e.,
N −1
1 X
x[N + m] = X[k]ej2πk(N +m)/N (6.75)
N k=0
N −1
1 X
= X[k]ej2πkm/N · e|{z}
j2πk
(6.76)
N k=0
1
≡ x[m] (6.77)
Hence, while we consider the DFT representation valid for finite-duration sequences, we
cannot ignore the inherent periodicity resulting from the DFT definitions. As we will show
next, all of the properties of the DFT can be deduced from the DFS by restricting the
observation in the time-domain n and the frequency domain k to a window of length N .
Specifically, 0 ≤ n ≤ N − 1 and 0 ≤ k ≤ N − 1.
c
°A Course on Digital Signal Processing, Dr. Aly Farag, 2005
6-20 CHAPTER 6. THE DISCRETE FOURIER TRANSFORM
Note:
a = b mod N if
b = a + iN, i = integer
Define
x̃1 [n] = x̃[n − m] = x[(n − m) mod N ] (6.83)
Recall that
X̃1 [k] = e−j2πkm/N X̃[k] (6.84)
½
x̃[n], 0 ≤ n ≤ N − 1
Now if x[n] =
0, otherwise
½
x̃1 [n] = x̃[n − m] = x[(n − m) mod N ], 0 ≤ n ≤ N
then x1 [n] =
0, otherwise
DF T
If x[n] ←→ X[k] (6.87)
then
DF T
x[(n − m) mod N ], 0≤n≤N −1 ←→ X[k]e−j2πkm/N (6.88)
c
°A Course on Digital Signal Processing, Dr. Aly Farag, 2005
6.4. PROPERTIES OF THE DFT 6-21
x[n]
0 N n
(a)
x̃[n]
0 N n
(b)
0 N n
(c)
x̃1 [n], 0≤n≤N −1
x1 [n] =
0, otherwise
0 N n
(d)
Figure 6.7: Circular shift of a finite-length sequence; i.e., the effect in the same time domain
of multiplying the DFT of the sequence by a linear phase factor.
¦¦¦
c
°A Course on Digital Signal Processing, Dr. Aly Farag, 2005
6-22 CHAPTER 6. THE DISCRETE FOURIER TRANSFORM
DF T
If x[n] ←→ X[k]
DF T
then X[n] ←→ N x[−k mod N ], 0 ≤ k ≤ N − 1
Note:
n mod N = n
−n mod N = N − n
Form
then
N
X −1
x3 [n] = x1 [m]x2 [(n − m) mod N ]
m=0
N
X −1
= x2 [m]x1 [(n − m) mod M ]
m=0
Proof :
From the DFS equation (periodic convolution)
If X̃3 [k] = X̃1 [k]X̃2 [k] then
N
X −1
x̃3 [k] = x̃1 [m]x̃2 [n − m]
m=0
Now let,
c
°A Course on Digital Signal Processing, Dr. Aly Farag, 2005
6.4. PROPERTIES OF THE DFT 6-23
½
x̃1 [n], 0 ≤ n ≤ N − 1
x1 [n] =
0, otherwise
½
x̃2 [n], 0 ≤ n ≤ N − 1
x2 [n] =
0, otherwise
i.e.,
x̃1 [n] = x1 [n mod N ]
x̃2 [n] = x2 [n mod N ]
Let, ½
x̃3 [n], 0 ≤ n ≤ N − 1
x3 [n] =
0, otherwise
½ PN −1
= m=0 x̃1 [m]x̃2 [n − m], 0 ≤ n ≤ N − 1
0, otherwise
Since,
x̃1 [m] = x1 [m] for 0 ≤ m ≤ N − 1
x̃2 [n − m] = x2 [(n − m) mod N ] for 0 ≤ m ≤ N − 1
Therefore,
N
X −1
x3 [n] = x1 [m]x2 [(n − m)/bmodN ]
m=0
x3 [n] = x1 [n] °
∗ x2 [n]
N
X −1
= x1 [m]x2 [(n − m) mod N ]
m=0
Example 7:
x1 [n] = δ[n − 1]
½ −n
a , o≤n≤4
x2 [n] =
0, otherwise
N = 5.
c
°A Course on Digital Signal Processing, Dr. Aly Farag, 2005
6-24 CHAPTER 6. THE DISCRETE FOURIER TRANSFORM
1 x1 [m] = δ[n − 1]
0 5 m
1 x2 [m]
0 5 m
n=0 x2 [−m]
0 5 m
0 5 m
x3 [n]
0 5 n
¦¦¦
c
°A Course on Digital Signal Processing, Dr. Aly Farag, 2005
6.4. PROPERTIES OF THE DFT 6-25
1
x1 [m]
0 1 2 3 4 5 6 7 m
1
x2 [m]
x̃2 [m]
0 1 2 3 4 5 6 7 m
n=0
x3 = 4 x2 [−m]
x̃2 [−m]
0 m
n=1
x3 = 4
0 m
n=2
x3 = 4
0 m
n=3
x3 = 4
0 m
n=4
x3 = 5
0 m
n=5
x3 = 6
0 m
6
5 5
x3 [n]
4 4 4 4 4
0 1 2 3 4 5 6 7 n
¦¦¦
c
°A Course on Digital Signal Processing, Dr. Aly Farag, 2005
6-26 CHAPTER 6. THE DISCRETE FOURIER TRANSFORM
1 x1 [m]
0 1 2 3 4 5 6 7 m
1 x2 [m]
x̃2 [m]
0 1 2 3 4 5 6 7 m
n=0 x2 [−m]
x3 = 1 x̃2 [−m]
0 m
0 m
0 m
n=3
x3 = 4
0 m
n=4
x3 = 3
0 m
n=5
x3 = 2
0 m
4
3 3 x3 [n]
2 2
1 1
0 1 2 3 4 5 6 7 n
¦¦¦
c
°A Course on Digital Signal Processing, Dr. Aly Farag, 2005
6.5. LINEAR CONVOLUTION USING THE DFT 6-27
∞
X
x3 [n] = x1 [m]x2 [n − m] (6.89)
m=−∞
Clearly, the product x1 [m]x2 [n − m] is zero for all m whatever n < 0 and n > L + P − 2.
Therefore, (L +P −1) is the maximum length of the sequence x3 [n] resulting from the Linear
Convolution of a sequence of length L with a sequence of length P .
c
°A Course on Digital Signal Processing, Dr. Aly Farag, 2005
6-28 CHAPTER 6. THE DISCRETE FOURIER TRANSFORM
x1 [n] = x2 [n]
1
n
0 L=P
(a)
n
0 2L − 1
(b) x3 [n − N ],
L N =L=6
n
0 N
(c)
x3 [n + N ],
L N =L=6
−N 0 n
(d)
x1 [n] °
∗ x2 [n]
L
N =L=6
n
0 N −1
(e)
x1 [n] °
∗ x2 [n]
N =L=6
0 2L − 1 n
(f )
Figure 6.11: Illustration that circular convolution is equivalent to linear convolution followed
by aliasing. (a) The sequences x1 [n] and x2 [n] to be convolved. (b) The linear convolution
of x1 [n] and x2 [n]. (c) x3 [n − N ] for N = 6. (d) x3 [n + N ] for N = 6. (e) x1 [n] °∗ x2 [n],
which is equal to the sum of (b), (c), and (d) in the interval 0 ≤ n ≤ 5. (f) x1 [n] °∗ x2 [n].
¦¦¦
c
°A Course on Digital Signal Processing, Dr. Aly Farag, 2005
6.5. LINEAR CONVOLUTION USING THE DFT 6-29
4. X[n] N x[((−k)N ]
9. x[n] X[((−k))N ]