Fourier Analysis A Signal Processing Approach PDF
Fourier Analysis A Signal Processing Approach PDF
Sundararajan
Fourier Analysis—
A Signal Processing
Approach
Fourier Analysis—A Signal Processing Approach
D. Sundararajan
123
D. Sundararajan
Formerly at Department of Electrical
and Computer Engineering
Concordia University
Montreal, QC, Canada
This Springer imprint is published by the registered company Springer Nature Singapore Pte Ltd.
The registered company address is: 152 Beach Road, #21-01/04 Gateway East, Singapore 189721,
Singapore
Preface
Transform methods dominate the study of linear time-invariant systems in all the
areas of science and engineering, such as circuit theory, signal/image processing,
communications, controls, vibration analysis, remote sensing, biomedical systems,
optics, acoustics. The heart of the transform methods is Fourier analysis. Several
other often used transforms are generalizations or specific versions of Fourier
analysis. It is unique in that it is much used in theoretical studies as well as in
practice. The reason for the latter case is the availability of fast algorithms to
approximate the Fourier spectrum adequately. For example, the existence and
continuing growth of digital signal and image processing are due to the ability to
implement the Fourier analysis quickly by digital systems. This book is written for
engineering, computer science, and physics students, and engineers and scientists.
Therefore, Fourier analysis is presented primarily using physical explanations with
waveforms and/or examples, keeping the mathematical form to the extent it is
necessary for its practical use. In engineering applications of Fourier analysis, its
interpretation and use are relatively more important than rigorous proofs. Plenty of
examples, figures, tables, programs, and physical explanations make it easy for the
reader to get a good grounding in the basics of Fourier signal representation and its
applications.
This book is intended to be a textbook for senior undergraduate- and
graduate-level Fourier analysis courses in engineering and science departments and
a supplementary textbook for a variety of application courses in science and
engineering, such as circuit theory, communications, signal processing, controls,
remote sensing, image processing, medical analysis, acoustics, optics, and vibration
analysis. For engineering professionals, this book will be useful for self-study. In
addition, this book will be a reference for anyone, student or professional, spe-
cializing in the practical applications of Fourier analysis. The prerequisite for
reading this book is a good knowledge of calculus, linear algebra, signals and
systems, and programming at the undergraduate level.
Programming is an important component in learning and practicing Fourier
analysis. A set of MATLAB® programs are available at the Web site of the book.
While the use of a software package is inevitable in most applications, it is better to
v
vi Preface
D. Sundararajan
Contents
1 Signals . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1
1.1 Basic Signals . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2
1.1.1 Unit-Impulse Signal . . . . . . . . . . . . . . . . . . . . . . . . . . 2
1.1.2 Unit-Step Signal . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4
1.1.3 Unit-Ramp Signal . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5
1.1.4 Sinusoids and Complex Exponentials . . . . . . . . . . . . . 5
1.2 Classification of Signals . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
1.2.1 Continuous, Discrete, and Digital Signals . . . . . . . . . . 13
1.2.2 Periodic and Aperiodic Signals . . . . . . . . . . . . . . . . . . 13
1.2.3 Even- and Odd-Symmetric Signals . . . . . . . . . . . . . . . 14
1.2.4 Energy and Power Signals . . . . . . . . . . . . . . . . . . . . . 17
1.2.5 Deterministic and Random Signals . . . . . . . . . . . . . . . 18
1.2.6 Causal and Noncausal Signals . . . . . . . . . . . . . . . . . . . 19
1.3 Signal Operations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19
1.3.1 Time Shifting . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19
1.3.2 Time Scaling . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20
1.4 Complex Numbers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22
1.5 Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25
2 The Discrete Fourier Transform . . . . . . . . . . . . . . . . . . . . . . . . . . . 31
2.1 The Exponential Function . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32
2.2 The Complex Exponential Function . . . . . . . . . . . . . . . . . . . . . 33
2.2.1 Euler’s Formula . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33
2.2.2 Real Sinusoids in Terms of Complex Exponentials . . . . 34
2.3 The DFT and the IDFT . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35
2.3.1 The DFT and the IDFT . . . . . . . . . . . . . . . . . . . . . . . 39
2.3.2 The Criterion of Approximation . . . . . . . . . . . . . . . . . 40
2.3.3 The Matrix Form of the DFT and IDFT . . . . . . . . . . . 42
vii
viii Contents
xiii
Abbreviations
1-D One-dimensional
2-D Two-dimensional
DC Sinusoid with frequency zero, constant
DFT Discrete Fourier transform
DIF Decimation in frequency
DIT Decimation in time
DTFT Discrete-time Fourier transform
FIR Finite impulse response
FS Fourier series
FT Fourier transform
IDFT Inverse discrete Fourier transform
IFT Inverse Fourier transform
LSB Least significant bit
LTI Linear time-invariant
PM Plus–minus
RDFT DFT of real-valued data
RIDFT IDFT of the transform of real-valued data
xv
Chapter 1
Signals
Signals convey some information. Signals are abundant in the applications of science
and engineering. Typical signals are audio, video, biomedical, seismic, radar, vibra-
tion, communication, and sonar. While the signals are mostly of continuous nature,
they are usually converted to digital form and processed by digital systems for effi-
ciency. In signal processing, signals are enhanced to improve their quality with some
respect, or some features are extracted, or they are modified in some desired way. A
signal, in its mathematical representation, is a function of one or more independent
variables. While time is the independent variable most often, it could be anything
else, such as distance. The analysis is equally applicable to all types of indepen-
dent variables. Signal or waveform is used to refer the physical form of a signal. In
its mathematical representation, a signal is referred as a function or sequence. This
usage is not strictly adhered.
The amplitude profile of most naturally occurring signals is arbitrary, and conse-
quently, it is difficult to analyze, interpret, transmit, and store them in their original
form. The idea of a transform is to represent a signal in an alternate, but equivalent,
form to gain advantages in its processing. Fourier analysis, the topic of this book,
provides a widely used representation of signals. As signal representation is the topic
of the book and the most suitable representation of a signal depends on its character-
istics, we have to first study the classification of signals. Further, the representation
is in terms of some well-defined basis signals, such as the sinusoid, complex expo-
nential, and impulse. Although practical signals are mostly real-valued, it becomes
mandatory to use the equivalent complex-valued signals for ease of mathematical
manipulation. In addition, operations such as shifting and scaling of signals are often
required in signal analysis. All these aspects are presented in this chapter.
The amplitude profile of most naturally occurring signals is arbitrary. These signals
are analyzed using some well-defined basic signals, such as the impulse, step, ramp,
sinusoidal, and exponential signals. In addition, systems, which are hardware or soft-
ware realizations, modify signals or extract information from them. They are also
characterized by the responses to these signals. The basic signals either have an infi-
nite duration or infinite bandwidth. For practical purposes, they are approximated to
a desired accuracy. Fourier analysis has four versions and each version uses different
type of signals. Therefore, it is necessary to study both the continuous and discrete
type of signals.
The unit-impulse and the sinusoidal signals are the most important signals in the
study of signals and systems. The continuous unit-impulse δ(t) is a signal with a
shape and amplitude such that its integral at the point t = 0 is unity. It is defined, in
terms of an integral, as ∞
x(t)δ(t) dt = x(0)
−∞
It is assumed that x(t) is continuous at t = 0 so that the value x(0) is distinct. The
product of x(t) and δ(t) is
x(t)δ(t) = x(0)δ(t)
The value of the function x(t), at t = 0, is sifted out or sampled by the defining
operation. By using shifted impulses, any value of x(t) can be sifted.
It is obvious that the integral of the unit-impulse is the unit-step. Therefore, the
derivative of the unit-step signal is the unit-impulse signal. The value of the unit-step
is zero for t < 0 and 1 for t > 0. Therefore, the unit area of the unit-impulse, as
the derivative of the unit-step, must occur at t = 0. The unit-impulse and the unit-
step signals enable us to represent and analyze signals with discontinuities as we do
with continuous signals. For example, these signals model the commonly occurring
situations such as opening and closing of switches.
The continuous unit-impulse δ(t) is difficult to visualize and impossible to realize
in practice. However, the approximation of it by some functions is effective in practice
and can be used to visualize its effect on signals and its properties. While there are
1.1 Basic Signals 3
other functions that approach an impulse in the limit, the rectangular function is
often used to approximate the impulse. The unit-impulse, for all practical purposes,
is essentially a narrow rectangular pulse with unit area. Suppose we compress it by
a factor of 2, the area, called its strength, becomes 1/2 = 0.5. The scaling property
of the impulse is given as
1
δ(at) = δ(t), a = 0
|a|
With a = −1, δ(−t) = δ(t) implying that the impulse is an even-symmetric signal.
For example,
1 1 1
δ(3t − 1) = δ 3 t − = δ t−
3 3 3
The independent variable is n and the dependent variable is δ(n). The only nonzero
value (unity) of the impulse occurs when its argument n =0. The shifted impulse
δ(n − k) has its only nonzero value at n = k. Therefore, ∞ n=−∞ x(n)δ(n − k) =
x(k) is called the sampling or sifting property of the impulse. For example,
∞
2
0
3n δ(n) = 1, 9n δ(n + 1) = 0, 4n δ(−n − 1) = 0.25,
n=−∞ n=0 n=−2
2 ∞
∞
2n δ(n − 1) = 2, 2n δ(n + 1) = 0.5, 3n δ(n − 3) = 27
n=0 n=−∞ n=−∞
The argument n + 1 of the impulse, in the second summation, never becomes zero
within the limits of the summation.
u(n)
r(n)
2
1
0 0 0
-3 -2 -1 0 1 2 3 -2 -1 0 1 2 3 4 5 -2 -1 0 1 2 3 4 5
n n n
Fig. 1.1 a The discrete unit-impulse signal, δ(n); b the discrete unit-step signal, u(n); c the discrete
unit-ramp signal, r (n)
4 1 Signals
For positive values of its argument, the value of the unit-step signal is unity and it
is zero otherwise. An arbitrary function can be expressed in terms of appropriately
scaled and shifted unit-step or impulse signals. By this way, any signal can be spec-
ified, for easier mathematical analysis, by a single expression, valid for all n. For
example, a pulse signal, shown in Fig. 1.2a, with its only nonzero values defined as
{x(1) = 1, x(2) = 1, x(3) = 1} can be expressed as the sum of the two delayed unit-
step signals shown in Fig. 1.2b, x(n) = u(n − 1) − u(n − 4). The pulse can also be
represented as a sum of delayed impulses.
3
x(n) = u(n − 1) − u(n − 4) = δ(n − k) = δ(n − 1) + δ(n − 2) + δ(n − 3)
k=1
The value u(0) is undefined and can be assigned a suitable value from 0 to 1 to suit
a specific problem. In Fourier analysis, u(0) = 0.5. A common application of the
unit-step signal is that multiplying a signal with it yields the causal form of the signal.
For example, the continuous signal sin(t) is defined for −∞ < t < ∞. The values
of sin(t)u(t) is zero for t < 0 and sin(t) for t > 0.
(a) (b) 1
1 u(n-1)
x(n)=u(n-1)-u(n-4)
u(n-1), -u(n-4)
x(n)
-u(n-4)
0 -1
-2 -1 0 1 2 3 4 5 -2 -1 0 1 2 3 4 5
n n
Fig. 1.2 a The pulse signal, x(n) = u(n − 1) − u(n − 4); b the delayed unit-step signals, u(n − 1)
and −u(n − 4)
1.1 Basic Signals 5
The discrete unit-ramp signal, shown in Fig. 1.1c, is also often used in the analysis
of signals and systems. It is defined as
n for n ≥ 0
r (n) =
0 for n < 0
It linearly increases for positive values of its argument and is zero otherwise.
The three signals, the unit-impulse, the unit-step, and the unit-ramp, are related
by the operations of sum and difference. The unit-impulse signal δ(n) is equal to
u(n) − u(n − 1), the first difference of the unit-step. The unit-step signal u(n) is
equal to ∞ k=0 δ(n − k), the running sum of the unit-impulse. The shifted unit-step
signal u(n − 1) is equal to r (n) − r (n − 1). The unit-ramp signal r (n) is equal to
∞
r (n) = nu(n) = kδ(n − k).
k=0
Sinusoids
The impulse and the sinusoid are the two most important signals in signal and system
analysis. The impulse is the basis for convolution and the sinusoid is the basis for
transfer function. The cosine and sine functions are two of the most important func-
tions in trigonometry. As these functions are the basis functions in Fourier analysis,
we have study them in detail.
The unit circle, defined by x 2 + y 2 = 1 and shown in Fig. 1.3, is a circle with its
center located at the origin and radius 1. For each point on the circle defined by the
coordinates (x, y), starting at (1, 0) and moving in the counterclockwise direction,
with θ ≥ 0 (the angle subtended by the x-axis and the line joining the point and the
origin), the sine (sin) and cosine (cos) functions are defined in terms of its coordinates
(x, y) as
cos(θ) = x and sin(θ) = y
Clearly, the sinusoids are of periodic nature. Any function defined on a circle will be a
periodic function of an angular variable θ. Therefore, the trigonometric functions are
also called circular functions. The argument θ is measured in radians or degrees. The
6 1 Signals
cos( ) = x
sin( ) = y
) >0
(-1,0) (0,0) (1,0) x
(0,-1)
radian is defined as the angle subtended between the x-axis and the line between the
point and the origin on the unit circle. One radian is defined as the angle subtended
by unit arc length. Since the circumference of the unit circle is 2π, one complete
revolution is 2π rad. In degree measure, 2π = 360◦ and π = 180◦ . One radian is
approximately 180/π = 57.3◦ .
A linear combination of sine and cosine functions is a sinusoid, in rectangular
form, given by
a cos(θ) + b sin(θ)
√
where a and b are real numbers with a = 0 or b = 0. With c = a 2 + b2 , and
cos(d) = a/c and sin(d) = b/c,
d du
sin(u) = cos(u) ,
dx dx
1.1 Basic Signals 7
where A (half the range of the function) is the amplitude of the sinusoid, ω is its
frequency in radians, and θ is the phase. The phase is measured with respect to the
reference waveform A cos(ωt). For example, the peak value of this waveform occurs
at t = 0 and its phase is defined to be zero. The first peak of the sine waveform
π
A sin(ωt) = A cos ωt −
2
occurs at ωt = π/2 rad and its phase is −π/2 rad or −90◦ . The period of the waveform
is the interval between ωt = 0 to ωt = 2π. Therefore, the period is T = (2π)/ω s.
The radian frequency is ω radians/second and the cyclic frequency is f = ω/(2π) =
1/T Hz.
Sum of Sinusoids with the Same Frequency
An important property of the sinusoids is that the sum of sinusoids of the same
frequency, but with arbitrary amplitudes and phases, is also a sinusoid of the same
frequency. In order to find the sum, we have to express the sinusoids in their rect-
angular form and sum the respective amplitudes of the sine and cosine components.
Consider the two sinusoids
Then,
With θ = 0 and φ = −π/2 (one sinusoid being the cosine and the other being sine),
the formula reduces to relation between the polar and the rectangular form of a
sinusoid.
Example 1.1 Determine the sinusoid that is the sum of two sinusoids
π
π
x(t) = 3 cos ωt + and y(t) = 2 sin ωt −
3 6
Solution
The second sinusoid can also be expressed as
π π
2π
y(t) = 2 cos ωt − − = 2 cos ωt −
6 2 3
Now,
π 2π
A = 3, B = 2, θ = ,φ = −
3 3
Substituting the numerical values in the equations, we get
π 2π
C= 32 + 22 + 2(3)(2) cos + =1
3 3
π π 2π
−1 3 cos + 2 cos − 2π −1 3 sin 3 + 2 sin − 3
ψ = cos 3 3
= sin = 1.0472 rad = 60◦
1 1
(a) 1 (b) 1
x(t)
x(t)
0 0
-1 -1
0 4 8 12 0 3 6 9
t t
(c) (d)
1 1
0.9239 0.8660
0.7071
0.5
0.3827
x(n)
x(n)
0 0
-0.1951 -0.2588
-0.5556
-0.7071
-0.8315
-0.9808 -0.9659
0 4 8 12 16 20 24 28 -12 -9 -6 -3 0 3 6 9
n n
π π
16 t); b sin( 12 t); c cos( 32 n − 4 ); d cos( 24 n + 6 )
Fig. 1.4 a cos( 2π 2π 2π 2π
For discrete sinusoids, the range of frequencies for unique representation is limited
due to sampling. Further, the cyclic frequency has to be a rational number (a ratio of
two integers, a/b with b = 0), since the samples of the sinusoid are defined only at
the sample points.
Cosine and sine waveforms are two important special cases of the sinusoid.
Figure 1.4a shows the continuous cosine waveform cos( 2π 16
t). The angular frequency
ω
is ω = 16 rad/s. The cyclic frequency is f = 2π = 16 Hz. The waveform repeats
2π 1
every 16 s. The period is T = 1f = 16 s. The amplitude is one. That is, the maximum
distance from the t-axis to either of the peaks of the waveform is one. As the peak
occurs at t = 0, the phase of the waveform is 0. Figure 1.4b shows the continuous sine
waveform sin( 2π 12
t). The angular frequency is ω = 2π 12
rad/s. The cyclic frequency is
ω
f = 2π = 12 Hz. The waveform repeats every 12 s. The period is T = 1f = 12 s. The
1
amplitude is one. As the peak occurs at t = 3, the phase of the waveform is − π2 rad.
The occurrence of the peak is delayed by 3 s, compared with the cosine waveform.
That is, 2π
12
(−3) = − π2 . Therefore, the sine waveform can be, equivalently, expressed
as cos( 2π
12
t − π2 ). The sine waveform can be obtained by shifting cos( 2π 12
t) by π2 rad
◦
(or 90 or 3 s or a quarter of a cycle) to the right. Alternately, the cosine waveform can
be considered as the advanced version of the sine waveform. The cosine waveform
10 1 Signals
leads the sine waveform by 90◦ or the sine waveform lags the cosine waveform by
90◦ .
Figure 1.4c shows the discrete sinusoid cos( 2π 32
n − π4 ). The angular frequency is
ω
ω = 32 rad. The cyclic frequency is f = 2π = 32 cycles per sample. The waveform
2π 1
x(t) = bt
is called the exponential function with base b. Our primary interest, in this book, is
the complex exponential function of the form
x(θ) = Ae jθ
e jθ + e− jθ e jθ − e− jθ
cos(θ) = and sin(θ) =
2 j2
1.1 Basic Signals 11
) >0
-1 1 Re
-j
Let θ = ωt + φ. Then,
Solution
Using Euler’s identity, the waveform can be expressed in terms of complex expo-
nentials as
1
x(n) = (e j ( 32 n− 3 ) + e− j ( 32 n− 3 ) )
2π π 2π π
2
π π
The complex frequency coefficients of the exponentials are 0.5e− j 3 and 0.5e j 3 .
The real parts of the coefficients are even-symmetric and the imaginary parts are
odd-symmetric. This redundancy is expected, since there are only two independent
values specifying the sinusoidal waveform (the amplitude and the phase).
(a) 0.9469
0.8660
(b) 0.4904
0.7518 0.4157
0.6088 0.3536
0.2778
0.4423
0.1913
0.2588
0.0975
xe(n)
0.0654
x(n)
0
-0.1305
-0.0975
-0.3214 -0.1913
-0.5 -0.2778
-0.6593 -0.3536
-0.7934 -0.4157
-0.8969 -0.4619
-0.9659 -0.5
0 4 8 12 16 20 24 28 0 4 8 12 16 20 24 28
n n
(c) 0.8660 (d)
0.7201 1.4401 real
0.6124 1.2247 imaginary
0.4811 0.9623
0.3314 0.6628
0.1690 0.3379
xo (n)
xc(n)
0 0
-0.1690 -0.3379
-0.3314 -0.6628
-0.4811 -0.9623
-0.6124 -1.2247
-0.7201 -1.4401
-0.8001 -1.6002
-0.8494 -1.6988
0 4 8 12 16 20 24 28 0 4 8 12 16 20 24 28
n n
π
√ √
32 n − 3 ); b 0.5 cos( 32 n); c 32 n); d cos( 32 n) + j 3 sin( 32 n)
3
Fig. 1.6 a cos( 2π 2π
2 sin( 2π 2π 2π
Solution
Using Euler’s identity, the waveform can be expressed in terms of complex expo-
nentials as
√
1 j ( 2π n ) − j ( 2π n) 3 j ( 2π n )
(e 32 − e− j ( 32 n ) )
2π
x(n) = (e 32 +e 32 )+
2
2 √
√
1 3 1 3 − j ( 2π n )
e j ( 32 n ) +
2π
= + − e 32
2 2 2 2
√ √
The coefficients of the exponentials are ( 21 + 2
3
) and ( 21 − 2
3
). The waveform is
shown in Fig. 1.6d.
Signals are classified into different types based on their characteristics. The classifi-
cation is an aid in selecting a suitable representation and processing.
1.2 Classification of Signals 13
The sinusoidal signals are defined by the values of the coordinates on a circle in
Fig. 1.3. In each rotation of a point on the circle, the same set of values are produced
indefinitely. This type of signals, such as the sine and cosine functions, is periodic
signals. While only one period of a periodic signal contains new information, peri-
odicity is required to represent signals such as power and communication signals. In
communication engineering, the message signal is aperiodic and the carrier signal is
periodic. Finite duration signals are represented, by the practically most often used
version of the Fourier analysis, assuming periodic extension. The finite signal is con-
sidered as the values of one period and concatenation of it indefinitely on either side
yields a periodic signal. A signal x(t) is said to be periodic, if x(t) = x(t + T ), for
all values of t from −∞ to ∞ and T > 0 is a positive constant. The minimum value
of T that satisfies the constraint is the period. A periodic signal shifted by an integral
number of its period remains unchanged. A signal that is not periodic is aperiodic,
such as the impulse, step and ramp signals shown in Fig. 1.1 and the real exponen-
tial. The period is infinity, so that there is no indefinite repetition. The everlasting
definition of a periodic signal is for mathematical convenience. In practice, physical
devices are switched on at some time and the response reaches a steady state, after
the transient response dies down.
14 1 Signals
r = k − (k/N )N , N = 0
and r has the same sign as N . The floor function rounds the number to the nearest
integer less than or equal to its argument. For example, with N = 3, r = k mod 3
yields
k –8 –7 –6 –5 –4 –3 –2 –1 0 1 2 3 4 5 6 7
r 1 2 0 1 2 0 1 2 0 1 2 0 1 2 0 1
r = k mod N = (k + N ) mod N
Let {1̌, 2, 3} is a periodic sequence with period 3. The 27th number in the sequence
is 1. The index is obtained as 27 mod 3 = 0 and x(0) = 1. x(−4) = x(2) = 3.
Any signal can be decomposed into its even and odd components. Knowing whether
a signal is even or odd may reduce computational and storage requirements in its
processing. If a signal x(t) satisfies the condition
then it is said to be even. The plot of such a signal is symmetrical about the vertical
axis at the origin. For example, the cosine waveforms, shown in Figs. 1.4a and 1.6b,
are even. For the signal in Fig. 1.6b,
2π 2π
0.5 cos (−n) = 0.5 cos n
32 32
then it is said to be odd. The plot of such a signal is antisymmetrical about the vertical
axis at the origin. For example, the sine waveforms, shown in Figs. 1.4b and 1.6c,
are odd. For the signal in Fig. 1.6c,
√ √
3 2π 3 2π
sin (−n) = − sin n
2 32 2 32
Any function can be decomposed into its even and components. Let the even and
odd components of x(t) be xe (t) and xo (t), respectively. Then,
Its even and odd components are shown in Fig. 1.6b, c. The integral of an even signal
between symmetric limits −T to T is equal to twice that over the limits 0 to T . The
integral of an odd signal between symmetric limits is zero. The product properties
are:
Circular Symmetry
In the DFT, a finite extent signal is extended periodically to make it a periodic signal.
As periodic signals are defined on a circle, the even and odd symmetries, defined on
16 1 Signals
a line, can also be defined emphasizing the cyclic nature of the signal. If a N -point
signal x(n) satisfies the condition
are even. The values at the beginning and at the middle can be arbitrary for a signal
with even number of elements and the other values satisfy x(n) = x(−n), when
placed on a circle. Considering the finite extent alone, the condition is
x(N − n) = x(n), 1 ≤ n ≤ N − 1
is even.
If a N -point signal x(n) satisfies the condition
and
{x(n), n = 0, 1, . . . , 6} = {0, −2, −6, −4, 4, 6, 2}
are odd. The values at the beginning and at the middle must be zero for a signal with
even number of elements and the other values satisfy x(n) = −x(−n), when placed
on a circle. Considering the finite extent alone, the condition is
x(N − n) = −x(n), 1 ≤ n ≤ N − 1
is odd. Even- and odd-symmetric 8-point arbitrary sequences are shown in Fig. 1.7.
1.2 Classification of Signals 17
x(2) = q x(2) = q
x(3) = r x(1) = p x(3) = r x(1) = p
even-symmetric odd-symmetric
Power is the rate of doing work, typically measured in watts. It is common to specify
devices by their power handling capacity. Devices, such as an electric motor, heater,
amplifier and a diesel engine, are characterized by their power rating. The energy of
a signal x(t) is measured by the power dissipated in a 1 resister due to a voltage
applied across it or a current passing through. The energy dissipated is
∞
E= |x(t)|2 dt
−∞
assuming that E is finite. Signals satisfying the condition E < ∞ are called energy
signals. All practical signals are energy signals. The energy of x(t) = 2e−3t , t ≥ 0
is ∞
2
E= |2e−3t |2 dt =
0 3
Sinusoids are not energy signals, since they have infinite energy. Such signals are
characterized by their power. The average power of a continuous signal is defined as
18 1 Signals
T
1 2
P = lim |x(t)|2 dt
T →∞ T − T2
For periodic signals, the average power can be computed over one period as
T
1 2
P= |x(t)|2 dt,
T − T2
where T is the period. The average power of the sine wave 2 sin( 2π
8
t) is
4
1 2π 1 4 2π
P= |2 sin t | dt =
2
1 − cos 2 t dt = 2
8 −4 8 4 −4 8
1 N
P = lim |x(n)|2
N →∞ 2N + 1
n=−N
For a periodic signal with period N , the average power can be determined as
N −1
1
P= |x(n)|2
N n=0
Periodic and aperiodic signals with finite average power are called power signals.
The average power of the sine wave sin( 2π
8
n) is
2
3
1 1
P= |x(n)|2 = (02 + (1)2 + 02 + (−1)2 ) =
8 n=0 4 2
will be different. While the amplitude profile of each of the signals will be different,
similarity of the time variation and frequency content are likely to be similar. Deter-
ministic signals are characterized by their amplitude in the time domain and Fourier
spectrum in the frequency domain.
Most signals occur at some finite instant, usually chosen as t = 0, and are considered
identically zero before this instant. A signal x(t) is said to be causal if
x(t) = 0, t < 0
If the variable t in x(t) is replaced by (t − t0 ), then the origin of the signal is shifted
to t = t0 . If t0 is positive (negative), the values of the function are retarded (advanced)
by t0 . Graphically, it amounts to shifting the plot of the function forward (t0 positive)
or backward by t0 . Examples of time shifting are the waveforms in Figs. 1.2 and 1.4.
Let x(n) = {x(0), x(1), x(2), x(3)} = {3, 1, 2, 4}. By linearly shifting x(n), we
get
2 1
x(2) 1 xs(2)
3 x(3) x(1) 2 xs(3) xs(1) 0
7
5 x(5) x(7) 4 xs(5) xs(7) 6
x(6) xs(6)
6 5
Circular Shifting
Circular shifting is simply the shifting of the values of a signal placed on a circle.
The right circular shift of a N -point signal x(n) by k sample intervals results in
x((n − k) mod N )
Right circular shift of the 8-point sequence x(n) = {0̌, 1, 2, 3, 4, 5, 6, 7} by one sam-
ple interval results in xs(n) = x(n − 1) = {7̌, 0, 1, 2, 3, 4, 5, 6}, as shown in Fig. 1.8.
The check symbolˇindicates that the index of that element is 0.
If the variable t in x(t) is replaced by (at), then the function is scaled. If a > 1, the
signal is compressed and if a < 1, the signal is expanded.
Signal Expansion
A N -point sequence x(n) is expanded by an integer factor a to get its expanded
version xu (n), n = 0, 1, . . . , a N − 1, defined as
n
x a for n = 0, ±a, ±2a, . . . ,
xu (n) =
0 otherwise
1.3 Signal Operations 21
The expanded signal xu (n) is obtained by inserting a − 1 zeros after each sample in
x(n). This operation, also called upsampling, increases the sampling rate. Expansion
of the 8-point sequence x(n) = {0̌, 1, 2, 3, 4, 5, 6, 7} by a factor of 2, (a = 2), results
in
xu (n) = {0̌, 0, 1, 0, 2, 0, 3, 0, 4, 0, 5, 0, 6, 0, 7, 0}
Signal Compression
A N -point sequence x(n) is compressed by an integer factor a to get its compressed
version xd (n), n = 0, 1, . . . , (N /a) − 1, defined as
The compressed signal xd (n) is obtained by taking every ath sample, starting with
x(0). This operation, also called downsampling, decreases the sampling rate. Com-
pression of the 8-point sequence x(n) = {0̌, 1, 2, 3, 4, 5, 6, 7} by a factor of 2 results
in xd (n) = x(2n) = {0̌, 2, 4, 6}.
Time-Reversal
Time-reversal of a signal x(t) is defined as xr (t) = x(−t) and xr (−t) = x(t). By
replacing t by −t, we get the time-reversed version of x(t), which is the mirror image
of x(t) about the vertical axis at the origin.
Circular time-reversal of a N -point signal x(n) is given by
x(0) for n = 0
x(N − n) 1 ≤ n ≤ N − 1
This is just plotting x(n) in the other direction on a circle. Circular time-reversal of
the 8-point sequence x(n) = {0̌, 1, 2, 3, 4, 5, 6, 7} results in xr (n) = x(N − n) =
{0̌, 7, 6, 5, 4, 3, 2, 1}, as shown in Fig. 1.9.
2 6
x(2) 1 xr(2)
3 x(3) x(1) 5 xr(3) xr(1) 7
4 x(4) 0
x(0) 4 xr(4) xr(0) 0
7
5 x(5) x(7) 3 xr(5) xr(7) 1
x(6) xr(6)
6 2
Zero Padding
In this operation, a sequence is appended by zero-valued samples. A N -point
sequence x(n) is expanded to a M-point, M > N , signal x z (n), n = 0, 1, . . . , M − 1,
defined as
x(n) for n = 0, 1, . . . , N − 1
x z (n) =
0 for n = N , N + 1, . . . , M − 1.
Complex number system is an extension of the real number system that suits a large
number of applications in science and engineering. The simplest number system is the
set of natural numbers {1, 2, 3, . . .}, the system we use to count things. By including
the negative numbers, we get the integers. Further, the number system is extended by
including rational and irrational numbers. With this system, we can only specify the
location of a point on a line. There is a necessity in several applications to represent a
point on a plane. For example, a sinusoid at a given frequency is characterized by its
amplitude and phase. That requires a pair of ordered numbers, a two-element vector.
While it is possible to represent a sinusoid with two scalars, the vector representation
is so much advantageous that it is used in most of the Fourier analysis, the subject
of this book. Another advantage of the complex number system is that it provides
solution to all polynomial equations. Further, real integrals, which may or may not be
evaluated by real integral calculus, are elegantly evaluated by complex integration.
Except that the system is, unfortunately, named as complex number system, there is
nothing complex about it and it is just another extension of the number system.
A complex number z = (x, y) is a two-element vector of real numbers, in which
the first and second elements are, respectively, called the real and imaginary parts of
z. A more commonly used notation for the complex number is z = x + j y, where
j is the imaginary unit. For example, the real part of z = (3 − j2) is 3 and the
imaginary part is −2. This form of a complex number is called its rectangular form.
Two complex numbers are equal if and only if their real parts are equal and their
imaginary parts are also equal.
The Complex Plane
As complex numbers are 2-element vectors, they can be represented in a plane, called
the complex plane. The complex plane, shown in Fig. 1.10, is similar to x y-plane used
to plot graphs. In the complex plane, the horizontal axis is called the real axis and
the vertical axis is called the imaginary axis. On both axes, the scale is the same. A
complex number is plotted as a point in the complex plane with its real and imaginary
parts fixing the coordinates of the horizontal and vertical axes, respectively. Several
examples are given in the figure. A number lying on the real axis, with its imaginary
part zero, is a real number. Therefore, it is obvious that the complex number system is
an extension of the real number system. A number lying on the imaginary axis, with
1.4 Complex Numbers 23
Imaginary
complex numbers in the 2 -2+j2
1+j2
complex plane
1 0+j1
-2+j0 Real
0
0+j0
-1 -1-j1
1-j2
-2
-2 -1 0 1 2
its real part zero, is a pure imaginary number. The number j is called the imaginary
unit.
Addition of Complex Numbers
The sum of two complex numbers p = a + jb and q = c + jd is defined as
p + p∗ p − p∗
and ,
2 j2
While r is unique for each complex number, θ + 2nπ is an argument for any integer
√n.
Restricting θ between 0 and 2π gives a unique value. For example, let p = 1 + j 3.
Then, √
√ −1 3
r = 1 + ( 3) = 2, and tan
2 2 = 60◦
1
π
Therefore, the polar form is 2e j 3 . Now,
√
2 cos(60◦ ) = 1 and 2 sin(60◦ ) = 3
r e jθ se jφ = r se j (θ+φ)
The generalization of this result is the De Moivre’s theorem. With n a positive integer
and p = r e jθ , p n = r n e jnθ .
Division in Polar Form
The division of two complex numbers r e jθ and se jφ is
r e jθ r
= e j (θ−φ)
se jφ s
For example,
2π π π √ √ √
(4e j 3 )/(2e j 3 ) = (2e j 3 ) = (−2 + j2 3)/(1 + j 3) = (1 + j 3)
1.5 Summary
• The impulse has its strength concentrated at a point, while the sinusoid is an
everlasting signal.
• The unit-step signal, which is related to the impulse, is also often used in the
representation and manipulation of signals.
• The sinusoidal signal is a linear combination of the well-known trigonometric
cosine and sine functions.
• While physical devices generate the sinusoidal signals, a mathematically equiv-
alent form, the complex exponential, is often used in signal and system analysis
due to its compact form and ease of manipulation.
• The sinusoidal signal is most often used to represent and manipulate signals, since
it provides easier interpretation of the signals and fast processing of operations.
• Signal classification aids the selection of the most suitable transform for its repre-
sentation and manipulation.
• Signal operations, such as shifting and scaling, are often used in signal manipula-
tion, in addition to arithmetic operations.
• The complex number system is an extension of the real number system and it
provides significant advantages in the analysis of signals and systems. A complex
number is an ordered pair of real numbers, a two-element vector. More efficient
processing is obtained, when closely related quantities are represented in a vector
form.
Exercises
1.1 Evaluate the summation.
∞
1.1.1 3n δ(n).
n=−∞
∞
* 1.1.2 (−0.5)(n−1) δ(n).
n=2
∞
1.1.3 2n δ(n + 2).
n=0
∞
1.1.4 (0.25)n δ(n + 1).
n=−∞
∞
1.1.5 (−2)(n+1) δ(n − 3).
n=−∞
1.2 Express the signal as a linear combination of scaled and shifted unit-impulses.
1.2.1 {x(0) = −2, x(1) = 1, x(2) = −1, x(3) = 3} and x(n) = 0 otherwise.
1.2.2 {x(0) = 3, x(−1) = 1, x(2) = −2, x(−3) = 4} and x(n) = 0 otherwise.
* 1.2.3 {x(0) = −2, x(−2) = 3, x(2) = −1, x(−3) = 3} and x(n) = 0 otherwise.
1.2.4 {x(0) = 3, x(−1) = 1, x(3) = −2, x(4) = 2} and x(n) = 0 otherwise.
1.3 Assume that the impulse is approximated by a rectangular pulse, centered at t = 0,
1
of width 2a and height 2a . Using this quasi-impulse, the signal x(t) is sampled. What
1.5 Summary 27
1.14 Given the values of the constants a and k, and the sinusoid x(n), find the
expression for the sinusoid x(an + k). Find the sample values of the two sinusoids
for one cycle, starting from n = 0. For expansion, assume that the undefined sample
values are zero.
1.14.1 x(n) = sin 2π n − π6 , a = −2, k = −1.
2π
8
1.14.2 x(n) = cos 8 n + π3 , a = 21 , k = 2.
* 1.14.3 x(n) = sin 2π 8
n − π3 , a = 21 , k = −8.
1.15 Given the values of the constants a and k, and the signal x(n), find the
expression for the signal x(an + k). Find the sample values of the two signals for
n = {−3, −2, −1, 0, 1, 2, 3}. For expansion, assume that the undefined sample val-
ues are zero.
* 1.15.1 x(0) = 3, x(1) = 1, x(2) = −4, x(3) = 2, and x(n) = 0 otherwise. a =
2, k = −1.
1.15.2 x(n) = (0.8)n . a = −2, k = 1.
1.15.3 x(n) = (0.6)n u(n). a = 13 , k = −2.
1.16 Simplify each expression to get it in the form a + jb.
1.16.1 (7 − j3) + (1 + j2)
* 1.16.2 (1 + j3) − (3 −√j1)
1.16.3 (2 − j4) + (3 + 2 −4)
1.17 Simplify each expression to get it in the form a + jb.
1.17.1 (−7 − j3)(1 + j2)
1.17.2 (1 + j3) − (−3 − j1)
* 1.17.3 2− j4
1− j3
1− j4
− 2− j3
1.19 Simplify each expression to get it in the form a + jb. Find the conjugate of the
expression and simplify that also in the form a + jb.
1.19.1 (1 − j3) + (3 + j2)
1.19.2 (2 + j3) − (3 − j1)
* 1.19.3 (2 − j4) + (3 + j2)
1.20
1.20.1 Solve x 2 − 1.5x + 1 = 0 for x. Verify the answer by multiplying the resulting
factors. √
1.20.2 Using De Moivre’s theorem, express (−1 √ − j 3)5 in the form a + jb. Verify
your results by finding the 5th roots of (−1 − j 3)5 .
* 1.20.3 Find the complex 5th roots of unity. Verify your results by raising each root
to its fifth power.
Chapter 2
The Discrete Fourier Transform
Transform means change in form. For example, we use the product rule to change
the form of the problem of finding the derivative of the product of two functions, so
that its derivative can be found easily. The idea of a transform, in signal analysis, is
to approximate practical signals, which usually have arbitrary amplitude profiles and
difficult to analyze in their original form, adequately in terms of well-defined basis
signals, such as the cosine and sine signals. Then, it is easier to interpret, analyze,
transmit, and store them. In the representation of a function in the form x(t), variable
t is the independent variable in a certain domain, designated as the time domain.
Since the time is the independent variable frequently (but not always), it is named
as the time domain. In the representation of a function in the form X (k), variable k,
which represents the frequency index of a frequency component, is the independent
variable in the frequency domain. Either representation completely specifies the given
function. While the frequency-domain representation of signals and systems looks
unnatural, it is convenient and efficient in signal and system analysis. For example, a
high-quality recording of a music signal requires frequency components in the range
0–20 kHz and the corresponding recording devices, amplifiers, and speakers should
have a good frequency response in that frequency range.
Fourier analysis is an indispensable representation of signals and systems in
science and engineering. There are many other representations of various entities.
Infinite points in a plane are represented by their x-axis and y-axis coordinates.
A place on earth is represented by its longitude and latitude. Any color can be speci-
fied by its red, green, and blue components. With all the mathematics, Fourier analysis
looks complex and difficult. But, it is not so. It is similar to finding the amount of
a set of coins. Let us say, we have a box of 1 cent, 10 cent, and 50 cent coins. We
can take one by one and add its value to a partial sum. We find the amount after the
values of all the coins are added. An alternate way is to decompose the coins into the
three denominations and count the number of coins in each. Multiplying the number
of different coins by their value and adding results in the amount. In Fourier analysis,
we decompose a signal in terms of its sinusoidal components. This decomposition
© Springer Nature Singapore Pte Ltd. 2018 31
D. Sundararajan, Fourier Analysis—A Signal Processing Approach,
https://doi.org/10.1007/978-981-13-1693-7_2
32 2 The Discrete Fourier Transform
enables the determination of the output of a system faster than other methods, in
addition to other advantages. This method is faster due to the orthogonality of the
sinusoids and the availability of fast algorithms for its practical realization. While
the principle behind Fourier analysis is simple, it is the mathematical details that
make it look complex and difficult. With sufficient practice, both paper-and-pencil
and programming, one can become proficient in the indispensable Fourier analysis.
Fourier analysis has four different versions to suit the different types of signals.
The DFT is the only version in which signals are represented in finite and discrete
form in both the domains. Further, fast algorithms are available for its implementa-
tion. Therefore, it is most often used in practice. It can approximate the other versions
of the Fourier analysis adequately. The DFT uses only a finite number of discrete
sinusoids to represent the signals. Therefore, it is easier to understand and the visu-
alization of the reconstruction of the waveforms is much simpler. The other versions
involve infinite sums or integrals requiring a detailed study of the convergence prop-
erties. As it is the simplest to study the concepts of the Fourier analysis and often
used in practice, the DFT is presented in this chapter followed by other versions in
later chapters.
x(n) = bn
where the base b = 1 is a positive constant and the exponent n is the independent
variable. An important property of the exponential function is that
bm bn = bm+n
8 × 16 = 23 24 = 23+4 = 27 = 128
2.1 The Exponential Function 33
The logarithm n of a positive real number x to the base b is the exponent of the
exponential function x = bn . The inverse of the exponential function x = bn (b = 1)
is the logarithmic function with base b.
log2 8 = 3 since 8 = 23
log10 100 = 2 since 100 = 102
1 n
loge 1 = 0 since 1 = e0 , e = lim 1+ ≈ 2.71828
n→∞ n
Oscillators and other physical systems generate waveforms those are a combination
of sinusoidal waveforms. However, it is found that the mathematically equivalent
34 2 The Discrete Fourier Transform
complex exponential is found convenient in the analysis of signals. The Euler’s for-
mula gives the relation between the sinusoidal functions and the complex exponential
e jθ = cos θ + j sin θ
t t2
x(t) = x(0) + ẋ(0) + ẍ(0) + · · ·
1! 2!
The dot notation for differentiation places a dot over the dependent variable. That is,
if x(t) is a function of t, then the derivative of x(t) with respect to t is ẋ(t). ẍ(t) is
the second derivative. For cos(θ) and sin(θ), the series expansions are
θ2 θ4 θ3 θ5
cos(θ) = 1 − + − · · · and sin(θ) = θ − + − ···
2! 4! 3! 5!
Since the derivative of e jθ with respect to jθ is itself, for any order, the series
expansion is
Solving equations
e jθ + e− jθ e jθ − e− jθ
cos θ = and sin θ =
2 j2
a N x N + a N −1 x N −1 + · · · + a2 x 2 + a1 x + a0
2.2 The Complex Exponential Function 35
Figure 2.1a shows a discrete periodic waveform with period 4 by dots. The corre-
sponding continuous waveform is shown in thin line for clarity only. The indepen-
dent variable n often represents time, and therefore, the graph n versus x(n), the
amplitude of the signal at the instant n, is called the time-domain representation,
although n may be other than time such as distance. Signals naturally occur in the
time-domain form. Figure 2.1b shows the representation of the same signal in the
frequency domain, called the spectrum. The graph k versus X (k) is the DFT represen-
tation of the signal. It shows the complex amplitudes, scaled by 4, of the constituent
complex exponentials of the signal. For example, X (0) = 8 indicates that the ampli-
tude of the DC component is 8/4 = 2, as shown in Fig. 2.1c by the dash-dot line.
(a) (b)
3.8660 8 imaginary
real
4
X(k)
x(n)
2.1340
1.5 1
0
-1
0.5 -1.7321
0 1 2 3 0 1 2 3
n k
(c) (d)
2
7
1
x(n)
6
-1
0 1 2 3 1.5 2 2.5
n p
π
Fig. 2.1 a A discrete periodic waveform, x(n) = 2 − cos( 2π4 n − 6 ) + cos(2 4 n), with period 4
2π
samples and b its frequency-domain representation; c the frequency components of the waveform
in a; d the square error in approximating the waveform in a using only the DC component with
different amplitudes
36 2 The Discrete Fourier Transform
Similarly, X (2) = 4 indicates that the amplitude of the frequency component with
frequency √index 2 is 4/4 = 1, as shown
√ in Fig. 2.1c by the dashed line. Coefficients
X (1) = − 3 + j and X (3) = − 3 − j represent the frequency component with
index 1, as shown in Fig. 2.1c by the continuous line.
√ 2π √ 2π
(− 3 + j)e j 4 n + (− 3 − j)e j3 4 n 2π 5π 2π π
= cos n+ = − cos n−
4 4 6 4 6
Both the time- and frequency-domain representations are equivalent and unique.
The DFT finds X (k) from x(n), called the forward transform. The IDFT finds x(n)
from X (k), called the inverse transform. The transformation may be regarded as the
change of the independent variables n and k.
The discrete periodic function x(n) with period 4, shown in Fig. 2.1a, is given by
2π π 2π
x(n) = 2 − cos n− + cos 2 n
4 6 4
√ √
= 2e j0 4 n + (−0.25 3 + j0.25)e j 4 n + e j2 4 n + (−0.25 3 − j0.25)e− j 4 n
2π 2π 2π 2π
2π √ 2π 2π √ 2π
= 2e j0 4 n + (−0.25 3 + j0.25)e j 4 n + e j2 4 n + (−0.25 3 − j0.25)e j3 4 n
(2.1)
Due to periodicity,
e j3 4 n = e j (4−1) 4 n = e j4 4 n e− j1 4 n = e− j
2π 2π 2π 2π 2π
4 n
For the given N = 4, x(n) and the exponentials are known. The Fourier synthesis
problem is to find x(n), given X (k) and the exponentials.
The four samples over one period are obtained from the equations for n =
0, 1, 2, 3.
√ √
{x(0) = (3 − 0.5 3), x(1) = 0.5, x(2) = (3 + 0.5 3), x(3) = 1.5}
2.3 The DFT and the IDFT 37
Figure 2.1b shows the frequency-domain representation of the waveform in (a), scaled
by 4. √ √
{X (0) = 8, X (1) = (− 3 + j), X (2) = 4, X (3) = (− 3 − j)}
It shows the complex amplitudes of its constituent complex exponentials (Eq. (2.1))
scaled by 4 (the period). While the form
2π π 2π
x(n) = 2 − cos n− + cos 2 n
4 6 4
This form uses the rectangular form of the sinusoid, while the earlier form uses
the polar form. Fourier representation expresses a function in terms of sinusoidal
functions. The last two equations are trigonometric polynomials. The frequency
indices of the terms are all integer multiple of the smallest one, called the fundamental.
The other terms are called the harmonics.
Given the samples of a waveform, the DFT is a tool to find the coefficients of its
constituent frequency components. The decomposition of a waveform is obtained
using the orthogonality property of the complex exponentials and sinusoids. Orthog-
onality of two complex sequences is that the sum of pointwise products of a sequence
and the conjugate of the other sequence is zero or a constant over a specified inter-
2π 2π
val. For the two complex exponential signals e j N kn and e j N ln over a period of N
samples, the orthogonality condition is given by
N −1
N (k−l)n
j 2π N for k = l
e =
0 for k = l
n=0
N −1
1 − e j2π(k−l)
e j N (k−l)n =
2π
2π(k−l)
= 0, for k = l
n=0 1 − ej N
This is also obvious from the fact that the sine and cosine waveforms are symmetrical
about the x-axis. The sum of the equidistant samples of a cosine or sine waveform,
38 2 The Discrete Fourier Transform
2π 2π
Table 2.1 Samples of complex exponentials e j 4 kn , k, n = 0, 1, 2, 3 and their conjugates e− j 4 kn
over an integral number of periods, with a nonzero frequency index is always zero.
The orthogonality property can be verified using the samples of e j 4 kn and e− j 4 kn
2π 2π
given in Table 2.1. The sum of the pointwise product of the values of each row in
the left table with the corresponding values of the rows in the right table yields zero,
except for the same row. For example, the sum of pointwise product of the last row
{1, − j, −1, j} in the left table with the corresponding row in the right table yields
4. In the three other cases, the sum is zero.
If we multiply both sides of Eq. (2.1) by e− jk 4 n , k = 0, 1, 2, 3 and sum the prod-
2π
3
2π n
x(n)e− jk 4 =
n=0
3
2π n √ 2π 2π √ 2π 2π
(2e j0 4 + (−0.25 3 + j0.25)e j 4 n + e j2 4 n + (−0.25 3 − j0.25)e j3 4 n )e− jk 4 n
n=0
3
e j0 4 n e− j0 4 n + 0 + 0 + 0 = (2)(4) = 8, k = 0
2π 2π
X (0) = 2
n=0
√
3
e j 4 n e− j 4 n + 0 + 0
2π 2π
X (1) = 0 + (−0.25 3 + j0.25)
n=0
√ √
= (−0.25 3 + j0.25)(4) = − 3 + j, k = 1
3
0 + 0 + e j2 4 n e− j2 4 n + 0 = 4, k = 2
2π 2π
X (2) =
n=0
√
3
e j3 4 n e− j3 4 n
2π 2π
X (3) = 0 + 0 + 0 + (−0.25 3 − j0.25)
n=0
√ √
= (−0.25 3 − j0.25)(4) = − 3 − j, k = 3
N −1
x(n)e− jk N n , k = 0, 1, 2, . . . , N − 1
2π
X (k) = (2.2)
n=0
e− j N kn = W Nkn , W = e− j N
2π 2π
2π
The sum of the complex exponentials e jk N n multiplied by their respective DFT
coefficients gets back the time-domain waveform. Therefore, the inverse DFT (IDFT)
equation is defined as
N −1
1 2π
x(n) = X (k)e jk N n , n = 0, 1, 2, . . . , N − 1 (2.3)
N k=0
As the DFT coefficients have been scaled by N , the factor N1 appears in the IDFT
definition. There are other ways to take care of this constant.
Let us prove that the DFT and IDFT definitions form a transform pair. Substituting
the definition for X (k) in the definition of the IDFT, we get
N −1 N −1
1 jk 2π n
x(l)e− jk N l
2π
x(n) = e N
N k=0 l=0
N −1 N −1
1
e jk N (n−l) = x(n)
2π
x(n) = x(l)
N l=0 k=0
since
N −1
N for n = l
e jk N (n−l)
2π
0 for n = l
k=0
40 2 The Discrete Fourier Transform
2 −1
N
− jk 2π N N N
X (k) = x(n)e N n , k=− ,− − 1 ,..., − 1 (2.4)
2 2 2
n=(− N2 )
2 −1
N
1 2π N N N
x(n) = X (k)e jk N n , n = − ,− − 1 ,..., − 1 (2.5)
N 2 2 2
k=−( ) N
2
This form is convenient in some derivations. When the spectrum is displayed in this
format, the interpretation of the spectral features is easier. The conversion of the data
or spectrum from one format to another involves circular shift by half the number of
samples. The spectrum
√ √
{X (0) = 2, X (1) = 2 − j 2, X (2) = 3, X (3) = 2 + j 2}
in center-zero format is
√ √
{X (−2) = 3, X (−1) = 2 + j 2, X (0) = 2, X (1) = 2 − j 2}
In Fourier analysis, the signal is reconstructed with respect to the least squares error
criterion. The DFT X (k) of the sequence x(n) of period N is also periodic of period
N . Then, with N even,
2.3 The DFT and the IDFT 41
2 −1
N
1 2π N N N
x(n) = X (k)e jk N n , n = − ,− − 1 ,..., − 1
N 2 2 2
k=−( N2 )
E= ⎝x(n) − 1 X a (k)e jk
2π
N n ⎠
N
n=−( N2 ) k=−( M−1
2 )
Differentiating this expression with respect to X a (k0 ) and setting the derivative equal
to zero, we get
⎛ ⎞
2 −1
N M−1
2
⎝x(n) − 1 X a (k)e jk
2π
N n ⎠ e jk0 2πN n = 0
N
n=−( N2 ) k=−( M−1
2 )
2 −1 2 −1
M−1 N N
1
2
j (k+k0 ) 2π 2π
X a (k) e N n = x(n)e jk0 N n
N
k=−( M−1
2 ) n=−( N2 ) n=−( N2 )
Since (k + k0 ) is an integer, the only nonzero term in the inner summation occurs
when k = −k0 . Therefore, we get
2 −1
N
2π
X a (−k0 ) = x(n)e jk0 N n
n=−( N2 )
2 −1
N
x(n)e− jk N n = X (k)
2π
X a (k) =
n=−( N2 )
For each k, the sum of pointwise product of x(n) and e− jk N n , with n varying from 0
2π
of the basis function for that k. The sum of products can be expressed as a matrix
formulation of the DFT definition. With N = 2, the DFT definition is
X (0) 1 1 x(0)
=
X (1) 1 −1 x(1)
The DFT of {x(0) = 2, x(1) = 3} is {X (0) = 5, X (1) = −1}. It can be verified that
IDFT gets back the time-domain samples.
With N = 4, the DFT definition is
⎡ ⎤ ⎡ ⎤⎡ ⎤
X (0) 1 1 1 1 x(0)
⎢ X (1) ⎥ ⎢ 1 − j −1 j⎥ ⎢ ⎥
⎢ ⎥ ⎢ ⎥ ⎢ x(1) ⎥
⎣ X (2) ⎦ = ⎣ 1 −1 1 −1 ⎦ ⎣ x(2) ⎦
X (3) 1 j −1 − j x(3)
X = Wx
where X is the coefficient vector, W is the transform matrix, and x is the input vector.
The transform matrix W is
⎡ 2π 2π 2π 2π ⎤ ⎡ − j0 ⎤ ⎡ ⎤
e− j0 4 0 e− j0 4 1 e− j0 4 2 e− j0 4 3 e e− j0 e− j0 e− j0 1 1 1 1
⎢ − j1 2π4 0 2π ⎥ ⎢ π ⎥
e− j1 4 3 ⎥ ⎢ e− j0 e− j 2 e− jπ e− j 2 ⎥ ⎢ ⎥
2π 2π 3π
⎢e e− j1 4 1 e− j1 4 2 1 − j −1 j
⎢ − j2 2π 0 2π ⎥ = ⎢ − j0 ⎥=⎢ ⎥
⎣e 4
2π
e− j2 4 1
2π
e− j2 4 2 e− j2 4 3 ⎦ ⎣ e e− jπ e− j2π e− j3π ⎦ ⎣ 1 −1 1 −1 ⎦
2π
e− j3 4 0 e − j3 2π
4 1 e − j3 2π
4 2
2π
e− j3 4 3
3π 9π
e− j0 e− j 2 e− j3π e− j 2 1 j −1 − j
Concisely,
1 −1 1
x= W X = (W ∗ )X
4 4
2.3 The DFT and the IDFT 43
The inverse and forward transform matrices are orthogonal. That is,
⎡ ⎤⎡ ⎤ ⎡ ⎤
1 1 1 1 1 1 1 1 1 0 0 0
1⎢⎢ 1 j −1 − j ⎥ ⎢ 1 − j −1
⎥⎢ j ⎥ ⎢0
⎥=⎢ 1 0 0⎥⎥
4 ⎣ 1 −1 1 −1 ⎦ ⎣ 1 −1 1 −1 ⎦ ⎣ 0 0 1 0⎦
1 − j −1 j 1 j −1 − j 0 0 0 1
⎡ ⎤
1 √ √
1 1 √ √
1 1 √ √
1 1 √ √
1
⎢1 2 2 − 22 − j 22 −1 − 22 + j 22 2 2 ⎥
⎢ 2 −j 2 −j j 2 +j 2 ⎥
⎢1 − −1 − j −1 j⎥
⎢ √ √
j √ √
j 1 √ √ √ √ ⎥
⎢ ⎥
⎢1 − 2−j 2 2 2 2 2 ⎥
− 22 + j 22
=⎢ 2 2 j 2 −j 2 −1 2 +j 2 −j ⎥
⎢1 −1 1 −1 1 −1 1 −1 ⎥
⎢ √ √ √ √ √ √ √ √ ⎥
⎢ ⎥
⎢ 1 − 22 + j 22 −j 2
2 +j 2
2 −1 2
2 −j 2
2 j 2 2
− 2 −j 2 ⎥
⎢ ⎥
⎣1 j −1 − j 1 j −1 − j⎦
√ √ √ √ √ √ √ √
2 2 − 22 + j 22 −1 − 22 − j 22 2 2
1 2 +j 2 j −j 2 −j 2
The samples of the complex exponential e− j N kn are called the twiddle factors.
2π
They are the N th roots of unity. The twiddle factors are periodic of periodic N .
They are called twiddle factors because multiplying a complex number with them is
changing the phase of the number only. The periodicity of the twiddle factors with
N = 8 and the discrete frequencies are shown in Fig. 2.2. At these discrete frequen-
cies, called the bins, the DFT coefficients are computed. The frequency increment of
the DFT spectrum is 1/8 cycles per sample, which is also the fundamental frequency.
The frequency index 0 corresponds to the DC, the average value of the time-domain
waveform.
Im
2π 2π
e−j 8 6 = j = e−j 8 14 = ...
√ √ 2 √ √
2π 2π 2π 2π
e−j 8 5 = − 22 +j 22 = e−j 8 13 = ... 3 8 1 e−j 8 7 = 2
2 +j 2
2
= e−j 8 15 = ...
8 8
2π 2π 4 2π 2π 2π
e−j 8 4 = −1 = e−j 8 12 = ... 8 e−j 8 nk
0 e−j 8 0 = 1 = e−j 8 8 = ...
Re
2π
√ √ 2π 2π
√ √ 2π
2 2 2 2
e−j 8 3 =− 2 −j 2 = e−j 8 11 = ... 5 7 e−j 8 1 = 2 −j 2 = e−j 8 9 = ...
8 8
6
8
2π 2π
e−j 8 2 = −j = e−j 8 10 = ...
Fig. 2.2 Periodicity of the twiddle factors with N = 8 and the discrete frequencies
is computed as
⎡ ⎤ ⎡ ⎤⎡ ⎤ ⎡ ⎤
X (0) 1 1 1 1 1 1
⎢ X (1) ⎥ ⎢ 1 − j −1 j ⎥⎢0⎥ ⎢1⎥
⎢ ⎥ ⎢ ⎥⎢ ⎥ = ⎢ ⎥
⎣ X (2) ⎦ = ⎣ 1 −1 1 −1 ⎦ ⎣ 0 ⎦ ⎣ 1 ⎦
X (3) 1 j −1 − j 0 1
1 2π 2π 2π
x(n) = (1 + e j 4 n + e j2 4 n + e j3 4 n )
4
1 π 1 for n = 0
= 1 + 2 cos n + cos(πn) =
4 2 0 for n = 1, 2, 3
The IDFT of the spectrum formally gets back the input δ(n).
⎡ ⎤ ⎡ ⎤⎡ ⎤ ⎡ ⎤
x(0) 1 1 1 1 1 1
⎢ x(1) ⎥ 1 ⎢ 1 j −1 − j ⎥⎢1⎥ ⎢0⎥
⎢ ⎥ ⎢ ⎥⎢ ⎥ = ⎢ ⎥
⎣ x(2) ⎦ = 4 ⎣ 1 −1 1 −1 ⎦ ⎣ 1 ⎦ ⎣ 0 ⎦
x(3) 1 − j −1 j 1 0
The transform matrix can be generated using this procedure, for any N , in software
implementation. That is, form the identity matrix of the required order and compute
the DFT of its rows or columns to get the DFT transform matrix.
2π
Example 2.2 The DFT of the DC signal, x(n) = e j0 4 n ,
is computed as
⎡ ⎤ ⎡ ⎤⎡ ⎤ ⎡ ⎤
X (0) 1 1 1 1 1 4
⎢ X (1) ⎥ ⎢ 1 − j −1 j ⎥⎢1⎥ ⎢0⎥
⎢ ⎥ ⎢ ⎥⎢ ⎥ = ⎢ ⎥
⎣ X (2) ⎦ = ⎣ 1 −1 1 −1 ⎦ ⎣ 1 ⎦ ⎣ 0 ⎦
X (3) 1 j −1 − j 1 0
The DFT spectrum is {X (0) = 4, X (1) = 0, X (2) = 0, X (3) = 0}. The spectrum of
the DC signal is nonzero only at k = 0, since its frequency index is zero. Using the
IDFT, we get back the input x(n).
⎡ ⎤ ⎡ ⎤⎡ ⎤ ⎡ ⎤
x(0) 1 1 1 1 4 1
⎢ x(1) ⎥ 1 ⎢ 1 j −1 − j ⎥ ⎢ ⎥ ⎢ ⎥
⎢ ⎥= ⎢ ⎥⎢0⎥ = ⎢1⎥
⎣ x(2) ⎦ 4 ⎣ 1 −1 1 −1 ⎦ ⎣ 0 ⎦ ⎣ 1 ⎦
x(3) 1 − j −1 j 0 1
2π
Example 2.3 The DFT of the alternating signal, x(n) = e j2 4 n ,
is computed as
⎡ ⎤ ⎡ ⎤⎡ ⎤ ⎡ ⎤
X (0) 1 1 1 1 1 0
⎢ X (1) ⎥ ⎢ 1 − j −1 j ⎥ ⎢ −1 ⎥ ⎢ 0 ⎥
⎢ ⎥ ⎢ ⎥⎢ ⎥=⎢ ⎥
⎣ X (2) ⎦ = ⎣ 1 −1 1 −1 ⎦ ⎣ 1 ⎦ ⎣ 4 ⎦
X (3) 1 j −1 − j −1 0
The spectrum of the alternating signal is nonzero only at k = 2, since its frequency
index is 2. Using the IDFT, we get back the input x(n).
⎡ ⎤ ⎡ ⎤⎡ ⎤ ⎡ ⎤
x(0) 1 1 1 1 0 1
⎢ x(1) ⎥ 1 ⎢ 1 j −1 − j ⎥ ⎢ ⎥ ⎢ ⎥
⎢ ⎥ ⎢ ⎥ ⎢ 0 ⎥ = ⎢ −1 ⎥
⎣ x(2) ⎦ = 4 ⎣ 1 −1 1 −1 ⎦ ⎣ 4 ⎦ ⎣ 1⎦
x(3) 1 − j −1 j 0 −1
is computed as
⎡ ⎤ ⎡ ⎤⎡ √ ⎤ ⎡ ⎤
X (0) 1 1 1 1 (3 − 0.5 3) √ 8
⎢ X (1) ⎥ ⎢ 1 − j −1 j⎥ ⎢ ⎥ ⎢ ⎥
⎢ ⎥ ⎢ ⎥⎢ √0.5 ⎥ = ⎢ − 3 + j ⎥
⎣ X (2) ⎦ = ⎣ 1 −1 1 −1 ⎦ ⎣ (3 + 0.5 3) ⎦ ⎣ √ 4⎦
X (3) 1 j −1 − j 1.5 − 3− j
2π
Example 2.5 The samples of one period of the complex exponential x(n) = e j3 4 n
are
{x(0) = 1, x(1) = − j, x(2) = −1, x(3) = j}
and ⎡ ⎤ ⎡ ⎤⎡ ⎤ ⎡ ⎤
X (0) 1 1 1 1 1 0
⎢ X (1) ⎥ ⎢ 1 − j −1 j ⎥⎢−j ⎥ ⎢0⎥
⎢ ⎥ ⎢ ⎥⎢ ⎥=⎢ ⎥
⎣ X (2) ⎦ = ⎣ 1 −1 1 −1 ⎦ ⎣ −1 ⎦ ⎣ 0 ⎦
X (3) 1 j −1 − j j 4
⎡ ⎤ ⎡ ⎤⎡ ⎤ ⎡ ⎤
x(0) 1 1 1 1 0 1
⎢ x(1) ⎥ 1 ⎢ 1 j −1 − j ⎥ ⎢ ⎥ ⎢ ⎥
⎢ ⎥ ⎢ ⎥⎢0⎥ = ⎢−j ⎥
⎣ x(2) ⎦ = 4 ⎣ 1 −1 1 −1 ⎦ ⎣ 0 ⎦ ⎣ −1 ⎦
x(3) 1 − j −1 j 4 j
Example 2.6 The samples of one period of the complex exponential x(n) =
π π
e j ( 4 n+ 4 ) = e j 4 e j 4 n are
2π 2π
1 1 1 1 1 1 1 1
x(0) = √ + j √ , x(1) = − √ + j √ , x(2) = − √ − j √ , x(3) = √ − j √
2 2 2 2 2 2 2 2
and
⎡ ⎤ ⎡ ⎤ ⎡ √1 + j √12
⎤ ⎡ ⎤
X (0) 1 1 1 1 2 √ √0
⎢ X (1) ⎥ ⎢ 1 − j −1 j ⎥⎢⎢ − √12 + 1 ⎥
j √2 ⎥ ⎢ 2 2 + j2 2 ⎥
⎢ ⎥ ⎢ ⎥⎢ ⎥=⎢ ⎥
⎣ X (2) ⎦ = ⎣ 1 −1 1 −1 ⎦ ⎣ − √12 − j √12 ⎦ ⎣ 0⎦
X (3) 1 j −1 − j √1 − j √12 0
2
⎡ ⎤ ⎡ ⎤⎡ ⎤ ⎡ √1 + j √12
⎤
x(0) 1 1 1 1 √ √0 2
⎢ x(1) ⎥ 1 ⎢ 1 j −1 − j ⎥ ⎢ 2 2 + j2 2 ⎥ ⎢
⎢ − √12 + j √12 ⎥
⎥
⎢ ⎥ ⎢ ⎥⎢ ⎥=⎢
⎣ x(2) ⎦ = 4 ⎣ 1 −1 1 −1 ⎦ ⎣ 0 ⎦ ⎣ − √12 −
⎥
j √12 ⎦
x(3) 1 − j −1 j 0 √1 − j √12
2
The complex exponential is the standard unit in Fourier analysis. The DFT of a
real sinusoid can be obtained using the Euler’s formula.
2π 1
k0 n + θ = (e jθ e j N k0 n + e− jθ e− j N k0 n )
2π 2π
x(n) = cos
N 2
2π N
cos k0 n ↔ (δ(k − k0 ) + δ(k − (N − k0 )))
N 2
2π N
sin k0 n ↔ (− jδ(k − k0 ) + jδ(k − (N − k0 )))
N 2
Example 2.7 The samples of one period of the cosine waveform x(n) = cos( 2π
4
n)
are {x(0) = 1, x(1) = 0, x(2) = −1, x(3) = 0} and
⎡ ⎤ ⎡ ⎤⎡ ⎤ ⎡ ⎤
X (0) 1 1 1 1 1 0
⎢ X (1) ⎥ ⎢ 1 − j −1 j ⎥⎢ 0⎥ ⎢2⎥
⎢ ⎥ ⎢ ⎥⎢ ⎥=⎢ ⎥
⎣ X (2) ⎦ = ⎣ 1 −1 1 −1 ⎦ ⎣ −1 ⎦ ⎣ 0 ⎦
X (3) 1 j −1 − j 0 2
⎡ ⎤ ⎡ ⎤⎡ ⎤ ⎡ ⎤
x(0) 1 1 1 1 0 1
⎢ x(1) ⎥ 1 ⎢ 1 j −1 − j ⎥ ⎢ ⎥ ⎢ ⎥
⎢ ⎥ ⎢ ⎥⎢2⎥ = ⎢ 0⎥
⎣ x(2) ⎦ = 4 ⎣ 1 −1 1 −1 ⎦ ⎣ 0 ⎦ ⎣ −1 ⎦
x(3) 1 − j −1 j 2 0
Example 2.8 The samples of one period of the sine waveform x(n) = sin( 2π
4
n) are
{x(0) = 0, x(1) = 1, x(2) = 0, x(3) = −1} and
⎡ ⎤ ⎡ ⎤⎡ ⎤ ⎡ ⎤
X (0) 1 1 1 1 0 0
⎢ X (1) ⎥ ⎢ 1 − j −1 j⎥ ⎢ ⎥ ⎢ ⎥
⎢ ⎥ ⎢ ⎥ ⎢ 1 ⎥ = ⎢ − j2 ⎥
⎣ X (2) ⎦ = ⎣ 1 −1 1 −1 ⎦ ⎣ 0 ⎦ ⎣ 0⎦
X (3) 1 j −1 − j −1 j2
⎡ ⎤ ⎡ ⎤⎡ ⎤ ⎡ ⎤
x(0) 1 1 1 1 0 0
⎢ x(1) ⎥ 1 ⎢ 1 j −1 − j ⎥ ⎢ ⎥ ⎢ ⎥
⎢ ⎥ ⎢ ⎥ ⎢ − j2 ⎥ = ⎢ 1 ⎥
⎣ x(2) ⎦ = 4 ⎣ 1 −1 1 −1 ⎦ ⎣ 0 ⎦ ⎣ 0⎦
x(3) 1 − j −1 j j2 −1
Example 2.9 The samples of one period of the sinusoid x(n) = cos( 2π n − π3 ) are
√ √ 4
{x(0) = 0.5, x(1) = 0.5 3, x(2) = −0.5, x(3) = −0.5 3} and
⎡ ⎤ ⎡ ⎤⎡ ⎤ ⎡ ⎤
X (0) 1 1 1 1 0.5
√ √0
⎢ X (1) ⎥ ⎢ 1 − j −1 j⎥ ⎢ ⎥ ⎢ ⎥
⎢ ⎥ ⎢ ⎥ ⎢ 0.5 3 ⎥ = ⎢ 1 − j 3 ⎥
⎣ X (2) ⎦ = ⎣ 1 −1 1 −1 ⎦ ⎣ −0.5 ⎦ ⎣ 0 ⎦
√ √
X (3) 1 j −1 − j −0.5 3 1+ j 3
2.3 The DFT and the IDFT 49
⎡ ⎤ ⎡ ⎤⎡ ⎤ ⎡ ⎤
x(0) 1 1 1 1 √0 0.5
√
⎢ x(1) ⎥ 1 ⎢ 1 j −1 − j ⎥ ⎢ j 3⎥ ⎢ ⎥
⎢ ⎥= ⎢ ⎥⎢1 − ⎥ = ⎢ 0.5 3 ⎥
⎣ x(2) ⎦ 4 ⎣ 1 −1 1 −1 ⎦ ⎣ ⎦ ⎣ −0.5 ⎦
√0 √
x(3) 1 − j −1 j 1+ j 3 −0.5 3
az n = {a, az, az 2 , . . . , }
is a geometric sequence, where a and z are some fixed numbers. The first value is a
constant. The rest of the values are the product of the preceding value by the common
ratio. A geometric series is a series composed of the terms of a geometric sequence.
For example,
N −1
= 1 + z + z 2 + · · · + z N −1 , z = e− j N
2π
SN =
n=0
L−1
1 − e− j N Lk
2π
ej N
2π L
2 k
− e− j N
2π L
2 k
e− j N nk =
2π
X (k) = =
1 − e− j N k e j N 2 − e− j N 2
2π 2π k 2π k
n=0
2π L
− j 2π (L−1) sin k − π
(L−1)k
sin Nπ Lk
=e N 2 k
k = e N
N 2 j
sin 2πN 2
sin Nπ k
Verify the DFT of δ(n) and DC signals, obtained in Examples 2.1 and 2.2, using this
formula.
Example 2.10 The samples of a signal are {x(0) = 1, x(1) = 1, x(2) = 0, x(3) =
0} and
⎡ ⎤ ⎡ ⎤⎡ ⎤ ⎡ ⎤
X (0) 1 1 1 1 1 2
⎢ X (1) ⎥ ⎢ 1 − j −1 j⎥ ⎢ ⎥ ⎢ ⎥
⎢ ⎥ ⎢ ⎥⎢1⎥ = ⎢1 − j ⎥
⎣ X (2) ⎦ = ⎣ 1 −1 1 −1 ⎦ ⎣ 0 ⎦ ⎣ 0⎦
X (3) 1 j −1 − j 0 1+ j
50 2 The Discrete Fourier Transform
⎡ ⎤ ⎡ ⎤⎡ ⎤ ⎡ ⎤
x(0) 1 1 1 1 2 1
⎢ x(1) ⎥ 1 ⎢ 1 j −1 − j ⎥⎢1 − j ⎥ ⎢1⎥
⎢ ⎥ ⎢ ⎥⎢ ⎥=⎢ ⎥
⎣ x(2) ⎦ = 4 ⎣ 1 −1 1 −1 ⎦ ⎣ 0⎦ ⎣0⎦
x(3) 1 − j −1 j 1+ j 0
Example 2.11 The samples of a signal are {x(0) = 1 + j1, x(1) = 2 − j1, x(2) =
1 + j2, x(3) = 2 + j2} and
⎡ ⎤ ⎡ ⎤⎡ ⎤ ⎡ ⎤
X (0) 1 1 1 1 1 + j1 6 + j4
⎢ X (1) ⎥ ⎢ 1 − j −1 j⎥ ⎢ ⎥ ⎢ ⎥
⎢ ⎥ ⎢ ⎥ ⎢ 2 − j1 ⎥ = ⎢ −3 − j ⎥
⎣ X (2) ⎦ = ⎣ 1 −1 1 −1 ⎦ ⎣ 1 + j2 ⎦ ⎣ −2 + j2 ⎦
X (3) 1 j −1 − j 2 + j2 3− j
⎡ ⎤ ⎡ ⎤⎡ ⎤ ⎡ ⎤
x(0) 1 1 1 1 6 + j4 1+ j1
⎢ x(1) ⎥ 1 ⎢ 1 j −1 − j ⎥ ⎢ −3 − j ⎥ ⎢ 2 − j1 ⎥
⎢ ⎥ ⎢ ⎥⎢ ⎥=⎢ ⎥
⎣ x(2) ⎦ = 4 ⎣ 1 −1 1 −1 ⎦ ⎣ −2 + j2 ⎦ ⎣ 1 + j2 ⎦
x(3) 1 − j −1 j 3− j 2+ j2
Fourier analysis has innumerable applications in science and engineering. All the
applications are based on the easier interpretation and characterization of the sig-
nal characteristics through the Fourier amplitude and power spectrum, its ability to
provide signal compression with adequate accuracy and reduce the computational
complexity of important operations such as convolution and correlation. One has to
adapt these abilities to suit the specific application. In this and later chapters, we
present some examples of the applications of Fourier analysis.
In image processing, objects in an image have to be identified. For that purpose, the
image is segmented using the properties of the objects. The segmented objects have
to be compactly represented. One way of characterizing an object is by its boundary
representation. A boundary can be described by its coordinates. The objective is to
minimize the storage requirements in representing it. Fourier boundary descriptor is
one of the effective methods to represent the boundary of an object.
A closed boundary is represented by a set of its coordinates in the spatial domain.
At each point on the boundary, a complex number is formed with its real part being the
x-coordinate and the imaginary part being the y-coordinate. The set of the complex
numbers is a periodic complex data, the period being the number of points on the
boundary. Let the N boundary coordinates be
2.4 Applications of the DFT and the IDFT 51
The 1-D DFT of this set, B(k), is the Fourier descriptor of the boundary with signif-
icant advantages. The 2-D data is represented by a 1-D data.
It is desirable that the descriptor is as much insensitive as possible for scaling,
translation, and rotation of the boundary. The properties of the DFT make it to relate
the Fourier descriptors of a boundary and its modified versions. Consider the 4 × 4
binary image x(m, n) and its shifted version x(m − 1, n − 1)
⎡ ⎤ ⎡ ⎤
1 1 1 0 0 0 0 0
⎢1 0 1 0⎥ ⎢0 1 1 1⎥
x(m, n) = ⎢
⎣1
⎥ x(m − 1, n − 1) = ⎢ ⎥
1 1 0⎦ ⎣0 1 0 1⎦
0 0 0 0 0 1 1 1
It is assumed that the top left corner is the origin. The DFT of b(n) is
The translation of the boundary can be found by the change in the DC coefficients
of the two DFTs, the remaining being the same.
Consider the 4 × 4 binary image x(m, n) and its 90◦ anticlockwise rotated version
xr (m, n) ⎡ ⎤ ⎡ ⎤
0 0 0 0 0 1 1 0
⎢1 1 1 1⎥ ⎢0 1 1 0⎥
x(m, n) = ⎢ ⎥ ⎢
⎣ 1 1 1 1 ⎦ xr (m, n) = ⎣ 0 1 1 0 ⎦
⎥
0 0 0 0 0 1 1 0
52 2 The Discrete Fourier Transform
Note that the coordinates are shifted due to rotation. The DFT of br (n) is
The DFT of the starting-point shifted complex data formed from the coordinates
of the boundary of b(n) can be obtained using the time-domain shift theorem. The
DFT of scaled complex data formed from the coordinates of the boundary of b(n) is
also the scaled version of B(k), due to the linearity of the DFT.
Figure 2.3a, b show, respectively, a triangular boundary and the normalized mag-
nitude of part of its Fourier descriptor. The first and the last 16 DFT coefficients
are shown by dots and crosses, respectively. A 464-point complex data sequence is
formed from the pair of 464 boundary coordinates and its DFT is computed. As the
data is arbitrary and complex, the DFT coefficients do not exhibit any symmetry.
Figure 2.3c, d show the reconstructed boundary using only 32 and 16, respectively,
of the largest of the 464 DFT coefficients. Despite the use of much fewer coefficients,
the reconstructed boundary is quite close to the original.
In Fourier analysis, a real signal is decomposed in terms of real sinusoids or com-
plex sinusoids with conjugate frequencies. The most famous example is the recon-
struction of a square wave from its Fourier spectrum. As the number of frequency
components is increased in the reconstruction, the synthesized waveform becomes
closer to the original waveform by constructive and destructive interferences.
In the Fourier boundary descriptor, the input signal is arbitrary and complex.
Therefore, the components to reconstruct a waveform are complex exponentials
with pure imaginary exponents, whose shape is a circle. The diameter of the circle
is proportional to the magnitude of the corresponding Fourier coefficient. As in
the case of real signals, the magnitude of the coefficients become negligible over a
considerable range of the spectrum. Therefore, a boundary can be represented with
fewer coefficients with a required accuracy.
Figure 2.4a shows the circles corresponding to three of the largest DFT
coefficients, in addition to the DC. The reconstructed boundary using these DFT
2.4 Applications of the DFT and the IDFT 53
(a) (b)
1
|B(k)| , normalized
0
0 4 8 12 448 463
k
(c) (d)
Fig. 2.3 a A triangular boundary; b the magnitude of the largest 32 of the 464 DFT coefficients
(normalized) of the boundary points; c and d the reconstructed boundaries using only the largest
32 and 16 DFT coefficients, respectively
(b) 80
(a)
60
50
40
20
0
-50 -20
-40
-50 0 50 -100 -50 0 50 100
Fig. 2.4 a Three circles corresponding to three DFT coefficients and the boundary corresponding
to their combined effect; b the reconstructed boundary using the DC and five other DFT coefficients
only
2.5 Summary
Exercises
2.1 Find the product of the two numbers after representing them in exponential form
with base 2.
2.1.1 256 and 128.
* 2.1.2 64 and 512.
2.1.3 32 and 128.
2.2 Using the Euler’s formula, find the complex exponential representation of the
signal in terms of: (i) the real and imaginary parts and (ii) amplitude and phase. Find
the samples of all the
three forms
and verify that they are the same.
2.2.1 x(n) = 4 cos π4 n − π3
* 2.2.2 x(n) = 2 cos π4 n + π6
√
2.2.3 x(n) = 3 cos π4 n − sin π4 n
2.3 Compute the DFT, X (k), of x(n) using the matrix form of the DFT. Compute the
IDFT of X (k) to get back x(n).
2.3.1 x(n) = {1, 2, 3, 4}
2.3.2 x(n) = {−2, −1, 3, 4}
2.3.3 x(n) = {3, −1, 2, 4}
2.3.4 x(n) = {1 + j3, 2 + j2, 1 − j1, 3 + j2}
* 2.3.5 x(n) = {1 + j3, 2 + j2, 3 + j1, 4 − j4}
2.3.6 x(n) = {3 + j3, 2 + j2, −1 + j1, 2 − j4}
2.4 Find the samples of x(n) over one period and use the matrix form of the DFT to
compute the spectrum X (k) of the set of samples. Using X (k), find the exponential
form of x(n) and reduce the expression to real form. Verify that the input x(n) is
obtained.
2.4.1 x(n) = 1 + 3 cos 2π n + π6 + 2 cos(πn).
4
* 2.4.2 x(n) = 1 − 2 sin 2π n − π − 3 cos(πn).
2π 4 π 3
2.4.3 x(n) = 1 − cos 4 n − 4 + cos(πn).
2.4.4 x(n) = 3 + sin 2π n − π4 − cos(πn).
4
2.4.5 x(n) = −1 − 2 cos 2π 4
n − π3 − 3 cos(πn).
Chapter 3
Properties of the DFT
In signal and system analysis, we frequently carry out operations on signals, such
as shifting, scaling, multiplication, differentiation, integration. The properties relate
the effect of an operation in one domain in the other. It is of interest to know the
time–frequency-domain correlations. It helps to select the appropriate domain for
interpretation and operation of signals. Further, the transforms of a set of related
signals can be determined more easily from the knowledge of the transform of some
simple signals.
3.1 Linearity
Let x(n) ↔ X (k) and y(n) ↔ Y (k), both the sequences with period N . Then,
where a and b are arbitrary constants. The DFT of a linear combination of a set of
signals is the same linear combination of the DFT of the individual signals. If
then
The value of the signal with index zero is indicated by a check mark on it. The length
of the two signals must be the same. If necessary, zero padding can be employed.
© Springer Nature Singapore Pte Ltd. 2018 57
D. Sundararajan, Fourier Analysis—A Signal Processing Approach,
https://doi.org/10.1007/978-981-13-1693-7_3
58 3 Properties of the DFT
3.2 Periodicity
ˇ 1 + j3, 0, 1 − j3}
x(n) = {3̌, 1, 2, 4} ↔ X (k) = {10,
−1
a+N
x(n)e− jk N n , k = 0, 1, 2, . . . , N − 1
2π
X (k) = (3.1)
n=a
where a is an arbitrary integer. Therefore, given a set of samples starting with index
other than zero, Eq. (3.1) can be used. Alternately, the given N -point sequence can
be periodically extended and the samples starting with index zero can be obtained.
Then, Eq. (3.1), with a = 0, can be used. For example,
{. . . , 2, 1, 2, 4, 2, 1, 2, 4, 2̌, 1, 2, 4, 2, 1, 2, 4, 2, 1, 2, 4, . . .}
using Eq. (3.1) with a = −2. Similarly, the IDFT can be computed using any suc-
cessive N samples of the periodic DFT spectrum.
Another implication of the periodicity is that the convolution and other operations
implemented using the DFT are periodic or circular or cyclic. However, the linear
convolution is often required. The DFT can still be used with sufficient zero padding.
Further, the periodic extension of a N -point sequence may create discontinuities at the
boundaries. The result is that the convergence of its spectral coefficients may be slow.
It requires more number of frequency components for a fairly good representation of
the signal. This is a disadvantage in applications such as signal compression. With
suitable extensions, such as making an even-symmetric extension, this problem can
be alleviated.
3.4 Circular Frequency Shifting 59
x(n ± n 0 ) ↔ e± j N kn 0 X (k)
2π
index k due to a shift of ±n 0 sampling intervals in the time domain. For example,
x(n − 1) = {4̌, 1, 2, 1} ↔ X (k) = {8̌, j2(− j), −4(−1), − j2( j)} = {8̌, 2, 4, 2}
After shifting, the signal becomes even-symmetric and, therefore, its DFT is also
even-symmetric. The computational complexity of computing the DFT of x(n) can
be reduced by shifting it to get xs(n), computing its DFT X s(k) and, then, deducing
the DFT of x(n) from X s(k) using the shift theorem.
With x(n) advanced by 2 sampling intervals, we get
x(n + 2) = {1̌, 4, 1, 2} ↔ X (k) = {8̌, j2(−1), −4(1), − j2(−1)} = {8̌, − j2, −4, j2}
e± j N k0 n x(n) ↔ X (k ∓ k0 )
2π
e− j N kn e j N k0 n
2π 2π
becomes
e− j N (k−k0 )n
2π
in the DFT definition, the spectral values get delayed by k0 sampling intervals and
occurs at frequency index k + k0 in the shifted spectrum. For example,
60 3 Properties of the DFT
ej
2π
4 n ˇ 2 + j2, −2}
x(n) = {3̌, j2, −1, − j4} ↔ X (k) = {2 − j2, 10,
ej
2π
4 2n ˇ 2 + j2}
x(n) = (−1)n x(n) = {3̌, −2, 1, −4} ↔ X (k) = {−2, 2 − j2, 10,
By multiplying x(n) by (−1)n and taking the DFT, we get the spectrum in the center-
zero format.
x(N − n) ↔ X (N − k)
The mod function returns the remainder of nk divided by 8. Each row of values, for a
specific k, is the time-reversal of that of (N − k). Therefore, x(N − n) ↔ X (N − k).
For example,
3.6 Duality
X (n) ↔ N x(N − k)
3.7 Transform of Complex Conjugates 61
Computing the DFT twice in succession of a signal x(n) yields N times the time-
reversal of x(n). The product of the transform matrix with itself yields a matrix whose
elements below the reverse diagonal are N (except the first entry) and, therefore, when
the input vector is multiplied by this matrix, we get a scaled and time-reversed version
of the input. With N = 8,
⎡ ⎤
1 √ √
1 1 √ √
1 1 √ √
1 1 √ √
1
⎢ 2 ⎥
⎢1 2
− j 2
− j − 2
− j 2
−1 − 22 + j 22 j 2 +j 2 ⎥
2
⎢ 2 2 2 2 ⎥
⎢1 − j −1 j 1 − j −1 j⎥
⎢ √ √ √ √ √ √ √ √ ⎥
⎢1 − 22 − j 22 − j − 22 + j 22 ⎥
2 −j 2 −1 2 +j 2
2 2 2 2
⎢ j ⎥×
⎢1 −1 1 −1 1 −1 1 −1 ⎥
⎢ √ √ √ √ √ √ √ √ ⎥
⎢ ⎥
⎢1 − 22 + j 22 − j 2
+ j 2
−1 2
− j 2
j − 22 − j 22 ⎥
⎢ 2 2 2 2 ⎥
⎣1 √ √
j −1 √
−
√
j 1 √ √
j −1 √
−
√
j⎦
1 2
2
+ j 2
2
j − 2
2
+ j 2
2
−1 − 22 − j 22 −j 2 −j 2
2 2
⎡ ⎤
1 1 1 1 1 1 1 1 ⎡ ⎤
√ √ √ √ √ √ √ √ x(0)
⎢ 2 ⎥
2 −j 2 − j − 22 − j 22 −1 − 22 + j 22 2 +j 2 ⎥
2 2 2
⎢1 j ⎢ ⎥
⎢ ⎥ ⎢ x(1) ⎥
⎢1 − j −1 j 1 − j −1 j ⎥ ⎢ x(2) ⎥
⎢ √ √ √ √ √ √ √ √ ⎥ ⎢ ⎥
⎢1 − 22 − j 22 j 2
− j 2
−1 2
+ j 2
− j − 22 + j 22 ⎥ ⎢ x(3) ⎥
⎢ 2 2 2 2 ⎥×⎢ ⎥
⎢1 −1 1 −1 1 −1 1 −1 ⎥ ⎢ x(4) ⎥
⎢ √ √ √ √ √ √ √ √ ⎥ ⎢ ⎥
⎢ ⎥ ⎢ ⎥
⎢1 − 22 + j 22 − j 2 +j 2
2 2
−1 2 −j 2
2 2
j − 22 − j 22 ⎥ ⎢ x(5) ⎥
⎢ ⎥ ⎣ x(6) ⎦
⎣1 √ √
j −1 √
−
√
j 1 √ √
j −1 √
−
√
j⎦
1 2
+ j 2
j − 2
+ j 2
−1 − 2
− j 2
−j 2
−j 2 x(7)
2 2 2 2 2 2 2 2
⎡ ⎤⎡ ⎤ ⎡ ⎤
8 0 0 0 0 0 0 0 x(0) x(0)
⎢0 0 0 0 0 0 0 8⎥ ⎢ ⎥ ⎢ x(7) ⎥
⎢ ⎥ ⎢ x(1) ⎥ ⎢ ⎥
⎢0 0 0 0 0 0 8 0⎥ ⎢ x(2) ⎥ ⎢ x(6) ⎥
⎢ ⎥⎢ ⎥ ⎢ ⎥
⎢0 0 0 0 0 8 0 0⎥ ⎢ ⎥ ⎢ ⎥
=⎢ ⎥ ⎢ x(3) ⎥ = 8 ⎢ x(5) ⎥ = 8x(8 − n)
⎢0 0 0 0 8 0 0 0⎥ ⎢ x(4) ⎥ ⎢ x(4) ⎥
⎢ ⎥⎢ ⎥ ⎢ ⎥
⎢0 0 0 8 0 0 0 0⎥ ⎢ ⎥ ⎢ x(3) ⎥
⎢ ⎥ ⎢ x(5) ⎥ ⎢ ⎥
⎣0 0 8 0 0 0 0 0 ⎦ ⎣ x(6) ⎦ ⎣ x(2) ⎦
0 8 0 0 0 0 0 0 x(7) x(1)
The first row of the first matrix, with k = 0, multiplied by the first column of the
second matrix and summed yields 8. For all the other rows, the sum of the product is 8
only with the (N − k)th column. In all other cases, rows and columns are orthogonal
and sum of the products is zero. For example, the DFT of {0̌, 1, 2, 3} is {6̌, −2 +
j2, −2, −2 − j2}. The DFT of this is 4{0̌, 3, 2, 1}.
N −1
N −1
∗ ∗ j 2π
x ∗ (N − n)e− j N nk
2π
X (k) = x (n)e N nk =
n=0 n=0
N −1
X ∗ (N − k) = x ∗ (n)e− j N nk
2π
n=0
For example,
ˇ j, 1 − j2, −6 + j, 1}
x(n) = {1̌, 4, j, 3} ↔ X (k) = {8 +
ˇ j, 1, −6 − j, 1 + j2}
x ∗ (n) = {1̌, 4, − j, 3} ↔ X ∗ (4 − k) = {8 −
ˇ j, 1 + j2, −6 − j, 1}
x ∗ (4 − n) = {1̌, 3, − j, 4} ↔ X ∗ (k) = {8 −
Let x(n) ↔ X (k) and h(n) ↔ H (k), both with period N . Then, the circular convo-
lution of the sequences is defined as
N −1
N −1
y(n) = x(m)h(n − m) = h(m)x(n − m), n = 0, 1, . . . , N − 1
m=0 m=0
The major difference between linear and circular convolutions is that, as the
sequences are periodic, the limits are changed from ±∞ to one period. Otherwise,
the convolution may become undefined as the sum may not remain finite. Summation
over additional periods is unnecessary, as it yields integer multiples of that of over
one period. The circular convolution of two 8-point periodic sequences x(n) and
h(n) is computed as follows. The sequences are placed on a circle, as shown in
Fig. 3.1, with one of the sequences time-reversed, h(n) as shown in (a). The sum of
the products of the corresponding values is the convolution output y(0). The time-
reversed sequence is shifted by one sample, as shown in (b). The sum of the products
of the corresponding values is the convolution output y(1). The procedure is repeated
to find the rest of the 6 outputs. The output will repeat after 8 shifts.
3.8 Circular Convolution and Correlation 63
h(6) h(7)
x(2) x(2)
h(5) x(3) x(1) h(7) h(6) x(3) x(1) h(0)
h(4) x(4) n=0 x(0) h(0) h(5) x(4) n=1 x(0) h(1)
N −1
N −1
X (k0 )e jk0 ω0 m H (k0 )e jk0 ω0 (n−m) = X (k0 )H (k0 )e jk0 ω0 n e jk0 ω0 (m−m)
m=0 m=0
is the same complex exponential with the coefficient N X (k0 )H (k0 ). The coefficient
is the scaled product of the two coefficients of the given exponentials.
2π
Let x(n) = e j 4 n . The samples of one period are {1, j, −1, − j}. The DFT
X (k) = {0, 4, 0, 0}. The pointwise product of X (k) with itself is {0, 16, 0, 0}, the
IDFT of which is 4{1, j, −1, − j}. We have used the convolution theorem to find
the convolution. We could have also used the defining equation of convolution in
the time domain, given above, to find the convolution. If we convolve x(n) with
2π
h(n) = e j3 4 n , the result is zero.
The convolution output of two complex exponentials, with frequencies k0 ω0 =
2π
k
N 0
and k1 ω0 = 2π N 1
k with complex coefficients X (k0 ) and H (k1 ), X (k0 )e jk0 ω0 n and
jk1 ω0 n
H (k1 )e
N −1
N −1
jk0 ω0 m jk1 ω0 (n−m) jk1 ω0 n
X (k0 )e H (k1 )e = X (k0 )H (k1 )e e jmω0 (k0 −k1 )
m=0 m=0
is zero.
The DFT representations of the sequences x(n) and h(n), in terms of complex
exponentials, are
64 3 Properties of the DFT
N −1 N −1
1 2π 1 2π
x(n) = X (k)e j N nk and h(n) = H (k)e j N nk
N k=0 N k=0
Since the coefficients of the convolution of the two signals in the frequency domain
are N X (k)H (k), the convolution of the sequences is given by
N −1
1 2π
y(n) = X (k)H (k)e j N nk
N k=0
That is, the IDFT of X (k)H (k) is the convolution of x(n) and h(n).
x(n)
∗ h(n) ↔ X (k)H (k)
The DFT representations of two 4-point sequences, x(n) and h(n), are
1 2π 2π 2π
x(n) = (X (0) + X (1)e j 4 n + X (2)e j2 4 n + X (3)e j3 4 n )
4
1 2π 2π 2π
h(n) = (H (0) + H (1)e j 4 n + H (2)e j2 4 n + H (3)e j3 4 n )
4
3.8 Circular Convolution and Correlation 65
Then,
x(n)h(n) = c(n) =
1 2π 2π 2π
(C(0) + C(1)e j 4 n + C(2)e j2 4 n + C(3)e j3 4 n
16
2π 2π 2π
+C(4)e j4 4 n + C(5)e j5 4 n + C(6)e j6 4 n )
where
This is the linear convolution of the two coefficient sequences. Since the signals are 4-
point periodic, only the first four frequency components have unique representation.
Frequency components with indices 4, 5, and 6 are added with those with indices 0,
1, and 2, respectively. Therefore, we get
This is the circular convolution of the two coefficient sequences. Therefore, the
scaled circular convolution of the two frequency-domain sequences X (k) and H (K )
corresponds to multiplication of the corresponding sequences in the time domain.
1
x(n)h(n) ↔ (X (k)
∗ H (k))
N
For example,
1 1 ˇ
x(n)h(n) = {3̌, −8, −1, 12} ↔ X (k)
∗ H (k) = {24, 16 + j80, −8, 16 − j80}
4 4
66 3 Properties of the DFT
Let x(n) ↔ X (k) and h(n) ↔ H (k), both with period N . The circular cross-
correlation of x(n) and h(n) is given by
N −1
r xh (n) = x( p)h ∗ ( p − n) , n = 0, 1, . . . , N − 1 ↔ X (k)H ∗ (k)
p=0
For example,
The cross-correlation output of x(n) and h(n) and its DFT are
The cross-correlation output of h(n) and x(n) and its DFT are
Since, with k = 0, the value of all the transform matrix coefficients is unity, X (0) is
sum of the input sequence values, x(n). With N even and k = N /2, the transform
matrix coefficients form the alternating sequence, {1, −1, 1, −1, . . . , −1}. There-
fore, X (N /2) is the difference between the sum of the even- and odd-indexed values
of x(n).
3.10 Upsampling of a Sequence 67
N −1
N −2
N −1
N
X (0) = x(n) and X = x(n) − x(n)
n=0
2 n=0,2 n=1,3
Coefficient X (0) is the sum of x(n). Coefficient X ( N2 ) is the alternating sum of x(n).
Similarly, in the frequency domain,
N −1
N −2 N −1
1 N 1
x(0) = X (k) and x = X (k) − X (k)
N k=0 2 N k=0,2 k=1,3
Sample x(0) is the average of X (k). Sample x( N2 ) is the alternating average of X (k).
For example,
x(n) = {1̌, −4, 1, 3} ↔ X (k) = {1̌, j7, 3, − j7}
X u (k) = X (k mod N ), k = 0, 1, . . . , L N − 1
N −1
L
xu (n)e− j L N nk , k = 0, 1, . . . , L N − 1
2π
X u (k) =
n=0
N −1
xu (m L)e− j L N m Lk
2π
X u (k) =
m=0
N −1
x(m)e− j N mk = X (k mod N ), k = 0, 1, . . . , L N − 1
2π
=
m=0
since N -point DFT is periodic of period N . X u (k) is the L-fold repetition of X (k).
ˇ 1, 3, 4}. Then, X (k) = {6̌, −5, + j3, −4,
Example 3.1 Let L = 3 and x(n) = {−2,
−5 − j3}.
ˇ 0, 0, 1, 0, 0, 3, 0, 0, 4, 0, 0}
xu (n) = {−2,
X u (k) = {6̌, −5, + j3, −4, −5 − j3, 6, −5, + j3, −4, −5 − j3,
6, −5, + j3, −4, −5 − j3}
Figure 3.2a shows the upsampled version of one cycle of x(n) = sin( 2π8
n) by
a factor L = 2. Its replicated spectrum is shown in (b). The spectrum of x(n) =
cos( 2π
8
n) upsampled by a factor L = 3 is shown in (c). The replicated waveform,
(a) (b)
1 4
X u(k)/j
x u(n)
0 0
-1 -4
0 2 4 6 8 10 12 14 0 1 7 9 15
n k
(c) (d)
4 0.3
X u(k)
x u(n)
0 -0.3
0 3 7 11 15 19 23 01 5 9 13 17 21
k n
Fig. 3.2 a Upsampled version of x(n) = sin( 2π8 n) by a factor L = 2; b its replicated spectrum;
c the spectrum of x(n) = cos( 2π
8 n) upsampled by a factor L = 3; d the corresponding scaled and
replicated waveform
3.11 Zero Padding the Data 69
with its amplitude reduced by a factor of 3, is shown in (d). Since the power of the
spectrum is reduced by a factor of 3 after upsampling, the amplitude of the waveform
is also reduced by a factor of 3.
X z (Lk) = X (k), k = 0, 1, . . . , N − 1
N −1
L
x z (n)e− j L N nk , k = 0, 1, . . . , L N − 1
2π
X z (k) =
n=0
N −1
x z (n)e− j L N nk , k = 0, 1, . . . , L N − 1
2π
X z (k) =
n=0
N −1
x z (n)e− j N nk = X (k), k = 0, 1, . . . , N − 1
2π
X z (Lk) =
n=0
Example 3.2 Let L = 2 and x(n) = {1̌, 2, 3, −4}. X (k) = {2̌, −2 − j6, 6, −2 +
j6}. Then,
The frequency increment of the spectrum is halved due to zero padding. Therefore,
the spectral values in X (k) become the even-indexed spectral values in X z (k).
Figure 3.3a, b shows, respectively, a signal with eight samples and its spectrum.
Figure 3.3c, d shows, respectively, the same signal padded up with eight zeros at the
end and the corresponding spectrum. The even-indexed spectral values are the same
70 3 Properties of the DFT
(a) 1
(b) 8
imaginary
real
X(k)
x(n)
0 0
0 2 4 6 0 2 4 6
n k
(c) 1 (d) 8
X z(k)
x z(n)
0 -6
0 2 4 6 8 10 12 14 0 2 4 6 8 10 12 14
n k
(e) (f) 1
3
2
X(k)
x(n)
0 0
-3
-1
0 2 4 6 0 2 4 6
k n
(g) (h)
3 0.5
2
X z(k)
x z(n)
0 0
-3 -0.5
0 1 2 3 4 5 6 7 8 9 1011121314 0 1 3 5 7 9 11 13
k n
Fig. 3.3 a and b shows, respectively, a signal with eight samples and its spectrum; c and d shows,
respectively, the same signal padded up with eight zeros at the end and the corresponding spectrum;
e and f shows, respectively, a spectrum with eight samples and the corresponding time-domain
signal; g and h shows, respectively, the same spectrum padded up with eight zeros in the middle of
the spectrum and the corresponding time-domain signal
as those shown in Fig. 3.3b. The odd-indexed spectral values are not specified by this
theorem. By zero padding at the end, we get interpolation of the spectral values.
A similar effect is observed in zero padding a spectrum. Fig. 3.3e, f shows,
respectively, a spectrum with eight samples and the corresponding time-domain sig-
nal. Figure 3.3g, h shows, respectively, the same spectrum padded up with eight
zeros in the middle of the spectrum (at the end in the center-zero format) and the
3.12 Symmetry Properties 71
Let the N -point sequence and its DFT be complex-valued. Writing the DFT definition
in the more explicit form using the rectangular form of the complex numbers with
− j 2π 2π 2π
e N nk
= cos nk − j sin nk ,
N N
we get
N −1
2π 2π
X r (k) + j X i (k) = (xr (n) + j xi (n)) cos nk − j sin nk (3.2)
n=0
N N
N −1
2π
X (k) = xr (n) cos nk
n=0
N
2π
and X (k) is real and even, as xr (n) cos N
nk is even and xr (n) sin 2π
N
nk is odd.
Figure 3.4c, d shows a real and even-symmetric signal and its real and even-symmetric
spectrum. For example,
N −1
2π
X (k) = − j xr (n) sin nk
n=0
N
2π
and X (k) is purely imaginary and odd, as xr (n) cos nk is odd and xr (n)
N
sin 2π
N
nk is even.
(a) (b)
2 real real
4 imaginary
X(k)
x(n)
0 0
-4
hermitian
-2
0 4 8 12 0 4 8 12
n k
(c) (d)
2 real and even 8 real and even
1
X(k)
x(n)
0 4
-1
0
0 4 8 12 0 4 8 12
n k
(e) (f)
2 real and odd 8 imginary and odd
X(k)
x(n)
0 0
-2 -8
0 4 8 12 0 4 8 12
n k
(g) (h)
1 4
0
X(k)
x(n)
0 0
-2 -8
0 4 8 12 1 3 5 7 9 11 13 15
n k
Fig. 3.4 a A real signal and b its hermitian-symmetric spectrum; c an even-symmetric real signal
and d its real and even-symmetric spectrum; e an odd-symmetric real signal and f its imaginary
and odd-symmetric spectrum; g a real signal with even half-wave symmetry and h its hermitian-
symmetric spectrum with zero-valued odd-indexed harmonics; i a real signal with odd half-wave
symmetry and j its hermitian-symmetric spectrum with zero-valued even-indexed harmonics
Figure 3.4e, f shows a real and odd-symmetric signal and its imaginary and odd-
symmetric spectrum. For example,
In all these cases, the summation range can be reduced by a factor of 2 and the
result multiplied by 2. Note that the real parts of the twiddle factors are the same
for frequency index k and N − k, while they are the negatives of each other for the
imaginary part.
The DFT coefficients for a real and even signal are real and even and those for
a real and odd signal are imaginary and odd. Therefore, the real part of the DFT
coefficients, Re(X (k)), of an arbitrary real signal x(n) are the DFT coefficients for
its even component xe (n) and j Im(X (k)) are those for its odd component xo (n).
It follows that the DFT of a complex signal x(n) + j y(n), where both the real and
imaginary parts are even, is also even.
The DFT of a complex signal x(n) + j y(n), where both the real and imaginary parts
are odd, is also odd.
Since the real sinusoids are related to conjugate complex exponentials by the
Euler’s formula
Figure 3.4a, b shows a real signal and its conjugate-symmetric spectrum. For example,
N
x n± = x(n),
2
then it is said to be even half-wave symmetric. Figure 3.4g, h shows an even half-wave
symmetric signal and its even-indexed spectrum. For example,
N
x n± = −x(n),
2
then it is said to be odd half-wave symmetric. Figure 3.4i, j shows an odd half-wave
symmetric signal and its odd-indexed spectrum. For example,
√ √
3 3 √ √
x(n) = , 0.5, − , −0.5 ↔ X (k) = {0, 3 − j, 0, 3 + j}
2 2
N −1
N −1
1
|x(n)|2 = |X (k)|2
n=0
N k=0
Orthogonal transforms, such as the Fourier analysis, have the power preservation
property.
The sums of the squared magnitude of the data sequence and that of the DFT coef-
ficients divided by 4 are equal and it is 43.
3.14 Summary 75
The generalized form of this theorem holds for two different signals as given by
N −1
N −1
1
x(n)y (n) =
*
X (k)Y * (k)
n=0
N k=0
This result follows from the circular correlation evaluated at output index zero.
3.14 Summary
• Properties relate the effect of an operation in one domain in the other. It helps to
select the appropriate domain for interpretation and operation of signals. Further,
the transforms of a set of related signals can be determined more easily.
• The DFT of a linear combination of a set of signals is the same linear combination
of the DFT of the individual signals.
• The DFT of a N -point signal is periodic of period N in the frequency domain. The
IDFT of the DFT is also periodic of period N in the time domain.
• The shift of a waveform in the time domain results in adding increments to the
phase of its frequency components, which are linearly proportional to the respective
frequency indices. There is no change in the amplitude.
• Multiplying a signal by a complex exponential with frequency index k0 results in
the shift of its spectrum by k0 sample intervals.
• The DFT of the time-reversal x(N − n) of a N -point signal is the time-reversed
version of the DFT X (k) of x(n), X (N − n).
• Computing the DFT twice in succession of a signal x(n) yields N times the time-
reversal of x(n).
• Convolution in the time domain corresponds to multiplication in the frequency
domain.
• The scaled circular convolution of the two frequency-domain sequences X (k) and
H (K ) corresponds to multiplication of the corresponding sequences in the time
domain.
• The DFT of the conjugate of x(n) of length N , x ∗ (n), is the frequency-reversed
and conjugated version of that of x(n), X ∗ (N − k).
• The DFT of the correlation of two sequences is the product of the DFT of the first
sequence multiplied by the conjugate of the DFT of the second sequence.
• Transform values X (0) and X (N /2) of a N -point sequence are, respectively, the
sum and alternating sum of x(n). Values x(0) and x(N /2) of a N -point sequence
are, respectively, the sum and alternating sum of the DFT of x(n), X (k), divided
by N .
• Upsampling a signal by a factor of L results in the L-fold repetition of its DFT.
• Zero padding a signal by a factor of L and computing its DFT results in a spectrum,
every Lth sample of which is the same as those of the DFT of the signal.
• The DFT of a real-valued signal is conjugate-symmetric.
76 3 Properties of the DFT
Exercises
3.1 Given two 4-point sequences x(n) and y(n), find the sequence z(n) = 3x(n) −
2y(n). Find the DFT Z (k) of z(n) using the linearity property with X (k) and Y (k)
and also directly from the definition. Verify that they are the same. Find the IDFT of
(Z (k) + 2Y (k))/3 to get back x(n).
3.1.1
x(n) = {2̌, 1, 3, 4}, y(n) = {2̌, 1, −3, 4}
* 3.1.2
ˇ 1, −3, 4}
x(n) = {1̌, 2, 3, 4}, y(n) = {−2,
3.1.3
x(n) = {2̌, 2, 1, 4}, y(n) = {2̌, 1, 3, −2}
3.2 Given a 4-point sequence x(n), find its DFT X (k). Find the values of x(23)
and X (−7) using the periodicity property. Compute the IDFT of X (k) with index
n = 23. Compute the DFT of x(n) with index k = −7. Verify that these values are
the same as those found using the periodicity property.
3.2.1
x(n) = {2̌, 1, 3, 3}
3.2.2
ˇ 1, 4, 3}
x(n) = {−1,
* 3.2.3
x(n) = {4̌, 2, 3, 2}
3.3 Given a 4-point sequence x(n), find its DFT X (k). Using the time-shift property,
find the DFT of x(n − k). Form the sequence x(n − k) and find its DFT. Verify that
both the DFTs are the same.
* 3.3.1
x(n) = {3̌, 1, 4, 3}, k = −1
3.3.2
ˇ 1, 1, 3}, k = 3
x(n) = {−1,
3.14 Summary 77
3.3.3
x(n) = {3̌, 2, 1, 2}, k = 2
3.4 Given a 4-point sequence x(n), find its DFT X (k). Using the frequency-shift
2π
property, find the DFT of xm(n) = e j 4 kn x(n). Form the sequence xm(n) and find
its DFT. Verify that both the DFTs are the same.
3.4.1
x(n) = {1̌, 2, 3, 1}, k = 1
* 3.4.2
ˇ 2, 1, 3}, k = −3
x(n) = {−2,
3.4.3
x(n) = {1̌, 4, 1, 2}, k = 2
3.5 Given a 4-point sequence x(n), find its DFT X (k). Using the time-reversal prop-
erty, find the DFT of xr (n) = x(4 − n). Form the sequence xr (n) and find its DFT.
Verify that both the DFTs are the same.
3.5.1
x(n) = {3̌, −2, 3, 1}
* 3.5.2
ˇ 1, 1, 3}
x(n) = {−3,
3.5.3
x(n) = {2̌, −4, 1, 2}
3.6 Given a 4-point sequence x(n), find its DFT X (k). Find the DFT of X (k). Verify
that it is equal to 4x(4 − n).
3.6.1
x(n) = {3̌, −2, 3, 1}
3.6.2
x(n) = {2̌, −2, 1, 1}
* 3.6.3
x(n) = {4̌, −2, 2, 1}
3.7 Given a 4-point sequence x(n), find its DFT X (k). Verify that x ∗ (n) ↔ X ∗
(4 − k).
3.7.1
x(n) = {1̌, j, 3, 2}
78 3 Properties of the DFT
3.7.2
x(n) = {2̌, −3, j, 2}
* 3.7.3
x(n) = {1̌, −4, −2, j}
3.8 Given two 4-point sequences x(n) and h(n), find the circular convolution output
y(n) = x(n) ∗ h(n), using the DFT and IDFT. Verify the output by using the time-
domain convolution expression.
* 3.8.1
x(n) = {1̌, 4, 3, 2}, h(n) = {1̌, −1, 3, 2}
3.8.2
x(n) = {3̌, 4, 3, 2}, h(n) = {1̌, −1, 4, 2}
3.8.3
x(n) = {1̌, 4, −3, −2}, h(n) = {2̌, −2, 3, 2}
3.9 Given two 4-point sequences x(n) and h(n), find the DFT of their product y(n) =
x(n)h(n), using the frequency-domain convolution property. Verify the computed
DFT with the DFT of y(n).
3.9.1
x(n) = {3̌, 1, 4, 2}, h(n) = {3̌, −2, 1, 2}
* 3.9.2
x(n) = {1̌, 2, 1, 2}, h(n) = {3̌, −3, 4, 2}
3.9.3
x(n) = {2̌, 1, 3, −2}, h(n) = {2̌, 1, 4, 3}
3.10 Given two 4-point sequences x(n) and h(n), find the circular cross-correlation
output r xh (n), using the DFT and IDFT. Verify the output by using the time-domain
correlation expression.
3.10.1
x(n) = {2̌, 3, 3, 2}, h(n) = {1̌, −3, 3, 2}
* 3.10.2
x(n) = {3̌, −1, 3, 2}, h(n) = {1̌, −1, 2, 2}
3.10.3
x(n) = {1̌, 3, −3, −2}, h(n) = {2̌, −2, 1, 2}
3.14 Summary 79
3.11 Given a 4-point sequence x(n), find its circular autocorrelation output r x x (n),
using the DFT and IDFT. Verify the output by using the time-domain correlation
expression.
3.11.1
x(n) = {4̌, 3, 2, 1}
3.11.2
x(n) = {1̌, −2, 3, 4}
* 3.11.3
x(n) = {1̌, −3, −2, −2}
3.12 Given a 4-point sequence x(n), find its DFT X (k). Verify that x(0) and x(2) are,
respectively, the sum and alternating sum of the its DFT X (k) divided by 4. Verify
that X (0) and X (2) are, respectively, the sum and alternating sum of x(n).
* 3.12.1
x(n) = {1̌, 3, 2, 1}
3.12.2
x(n) = {3̌, −2, 3, 4}
3.12.3
x(n) = {4̌, −3, −2, −2}
3.13 Given a 2-point sequence x(n), find its DFT X (k). Find the DFT of the upsam-
pled x(n) by a factor of 2 using the theorem. Find the IDFT of this DFT and verify
that we get upsampled x(n).
3.13.1
x(n) = {1̌, 3}
3.13.2
x(n) = {3̌, −2}
* 3.13.3
x(n) = {4̌, −3}
3.14 Given a 2-point sequence x(n), find its DFT X (k). Find the IDFT, x_r ep(n), of
the upsampled X (k) by a factor of 2. Verify that 2x_r ep(n) is the replicated x(n).
3.14.1
x(n) = {4̌, 2}
3.14.2
x(n) = {1̌, 3}
80 3 Properties of the DFT
* 3.14.3
ˇ 3}
x(n) = {−2,
3.15 Given a 2-point sequence x(n), find its DFT X (k). Zero pad x(n) by 2 zeros to
get x z(n). Find the DFT, X Z (k), of x z(n) and verify that the even-indexed samples
of X Z (k) are the same as X (k).
* 3.15.1
x(n) = {1̌, 2}
3.15.2
x(n) = {5̌, 3}
3.15.3
ˇ 3}
x(n) = {−4,
3.16 Given a 4-point sequence x(n), find its DFT X (k). What is the type of x(n).
3.16.1
x(n) = {1̌, 2, 1, 2}
3.16.2
x(n) = {3̌, 1, −3, −1}
3.16.3
ˇ 3, 1, 3}
x(n) = {−4,
3.16.4
x(n) = {5̌, 3, 2, 4}
* 3.16.5
x(n) = {0̌, −3, 0, 3}
3.17 Given a 4-point sequence x(n), find its DFT X (k). Verify Parseval’s theorem.
3.17.1
x(n) = {1̌, 2, 3, 1}
* 3.17.2
x(n) = {5̌, 3, 2, 4}
3.17.3
ˇ 3, 1, 3}
x(n) = {−4,
Chapter 4
Two-Dimensional DFT
x(n 1 , n 2 , . . . , n L ), n 1 = 0, 1, . . . , N1 − 1,
n 2 = 0, 1, . . . , N2 − 1, . . . , n L = 0, 1, . . . , N L − 1
is defined as
1 −1 N 2 −1 L −1
N N
− j2π
k1 k k
n 1 + N2 n 2 +···+ NL n L
X (k1 , k2 , . . . , k L ) = ··· x(n 1 , n 2 , . . . , n L )e N1 2 L
n 1 =0 n 2 =0 n L =0
(4.1)
In 2-D Fourier analysis, an arbitrary waveform, which is a surface, is represented in
terms of sinusoidal surfaces of harmonic frequencies in two orthogonal directions.
For example, the 2-D DFT coefficient X (k, l) is the coefficient of the 2-D com-
plex exponential with frequency indices (k, l). In determining the coefficients, the
orthogonality principle is used, as in the case of 1-D signals. However, it is easier
to interpret and compute the 2-D DFT as two sets of 1-D DFTs in two orthogonal
directions. The 1-D DFT can be generalized to three or more dimensions in a way
similar to that of the 2-DFT. The task in 2-D DFT is to represent images, such as that
shown in Fig. 4.1, in terms of sinusoidal surfaces.
x(m, n) = e j ( 8 (m+n)) , m, n = 0, 1, . . . , 7
2π
x0 (m) = e j ( 8 (m+0)) = e j , x1 (m) = e j ( 8 (m+1)) = e j
2π 2π 2π 2π 2π 2π
8 0 ej 8 m 8 1 ej 8 m ,
x6 (m) = e j ( 8 (m+6)) = e j 8 6 e j 8 m , x7 (m) = e j ( 8 (m+7)) = e j 8 7 e j 8 m
2π 2π 2π 2π 2π 2π
respond, respectively, to 1 and −1. The frequency in both the directions is 1/8
84 4 Two-Dimensional DFT
(a) (b)
0 0
1 1
2 2
3 3
m
m
4 4
5 5
6 6
7 7
0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7
n n
(c) 0
(d) 0
32 32
64 64
96 96
128 128
m
160 160
192 192
224 224
cycles/sample. The 256 × 256 image representations of the real and imaginary parts
of x(m, n) = e j ( 256 (3m+2n)) are shown, respectively, in Fig. 4.2c, d. The frequency
2π
along the m and n directions are 3/256 cycles/sample and 2/256 cycles/sample,
respectively.
Taking the 1-D DFT of the exponentials along the columns of x(m, n) = e j ( 8 (m+n)) ,
2π
Taking the 1-D DFT of the partial transform X (k, n) along the rows, we get
the 2-D DFT coefficients of e j ( 8 (m+n)) in the standard and center-zero formats,
2π
respectively, as
⎡ ⎤ ⎡ ⎤
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
⎢ 0 64 0 0 0 0 0 0 ⎥ ⎢0 0 0 0 0 0 0 0⎥
⎢ ⎥ ⎢ ⎥
⎢0 0 0 0 0 0 0 0⎥ ⎢0 0 0 0 0 0 0 0⎥
⎢ ⎥ ⎢ ⎥
⎢0 0 0 0 0 0 0 0⎥ ⎢0 0 0 0 0 0 0 0⎥
X (k, l) = ⎢
⎢0 0 0 0 0 0 0 0⎥
⎥ X (k, l) = ⎢
⎢0
⎥
⎢ ⎥ ⎢ 0 0 0 0 0 0 0⎥ ⎥
⎢0 0 0 0 0 0 0 0⎥ ⎢0 0 0 0 0 64 0 0 ⎥
⎢ ⎥ ⎢ ⎥
⎣0 0 0 0 0 0 0 0⎦ ⎣0 0 0 0 0 0 0 0⎦
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
By swapping the quadrants of the spectrum, we get one format from the other. The
nonzero DFT coefficient X (1, 1) = 64 is the scaled amplitude of the exponential
in the frequency domain. Taking the 1-D IDFT of X (k, l) along the rows, we get
X (k, n). Now, taking the 1-D IDFT of X (k, n) along the columns, we get back
x(m, n).
Since
e j ( 8 (m+n)) + e− j ( 8 (m+n))
2π 2π
2π
cos (m + n) = ,
8 2
Since
j 2π
8 (m+n) −j 2π
8 (m+n) j 2π
8 (m+n) −j 2π
8 (m+n)
2π e −e − je + je
sin (m + n) = = ,
8 j2 2
The general form of the 2-D complex exponential with a complex coefficient is
(b)
(a) 63 X (62,63) = 2048
x(m,n) 1
l
-1
63 0 X (2,1) = 2048
63
32 0 62
16 32 k
m 0 0 n
(c) (d)
2 63 X (62,63) = -j4096
x(m,n)
0 l
-2
63 0 X (2,1) = j4096
63
32 0 62
16 32
m n k
0 0
(e) (f)
3 63 X (62,63) = 4344.5- j4344.5
x(m,n)
0
l
-3
63 0 X (2,1) = 4344.5+ j4344.5
63
32 0 62
12 24 k
m 0 0 n
Fig. 4.3 a The 64 × 64 sinusoidal surface x(m, n) = cos( 2π 64 (2m + n)); b its spectrum; c the 64 ×
π
64 sinusoidal surface x(m, n) = 2 cos( 2π
64 (2m + n) + 2 ); d its spectrum; e the 64 × 64 sinusoidal
π
surface x(m, n) = 3 cos( 2π
64 (2m + n) + 4 ); f its spectrum
is shown in (b). Figure 4.4d shows the Fourier reconstructed pulse with the first 4 × 4
frequency components around X (0, 0). Figure 4.4e shows the Fourier reconstructed
pulse with the first 8 × 8 frequency components around X (0, 0). Figure 4.4f shows
the Fourier reconstructed pulse with all the frequency components. As more and
88 4 Two-Dimensional DFT
(a) (b)
1
log 10(1+|X(k,l)|)
x(m,n) 2
0 0
24 8
16 24 0 8
8 16 -8 0
8 -8
m 0 0 n k -16 -16 l
(c) (d)
0.25
1
xr(m,n)
xr(m,n)
0
0
24 24
16 24 16 24
8 16 8 16
8 8
m 0 0 n m 0 0 n
(e) (f)
1
1
xr(m,n)
xr(m,n)
0
0
24 24
16 24 16 24
8 16 8 16
8 8
m 0 0 n m 0 0 n
Fig. 4.4 a A 32 × 32 square pulse; b its log magnitude spectrum in the center-zero format; c its
Fourier reconstruction with just the DC component; d with the first 4 × 4 frequency components;
e with the first 8 × 8 frequency components; f with all the frequency components
more of frequency components are used in the reconstruction, the signal approaches
its original version through constructive and destructive interference of the frequency
components.
Let us compute a 2-D DFT similar to this problem but of size 4 × 4. Let the input
signal x(m, n) be
4.1 Two-Dimensional DFT as Two Sets of 1-D DFTs 89
⎡ ⎤ ⎡ ⎤
0 0 0 0 0
⎢0 1 1 0⎥ ⎢1⎥
x(m, n) = ⎢
⎣0
⎥=⎢ ⎥ 0 1 1 0
⎦ ⎣ ⎦
1 1 0 1
0 0 0 0 0
This signal can be expressed as the product of a column vector and a row vector.
This type of signals is called separable signals. The 2-D DFT can be computed using
1-D DFT. The 1-D DFT of {0, 1, 1, 0} is {2, −1 − j, 0, −1 + j}. The 2-D DFT of
x(m, n) is
⎡ ⎤ ⎡ ⎤
2 4 −2 − j2 0 −2 + j2
⎢ −1 − j ⎥ ⎢ 2⎥
⎢ ⎥ 2 −1 − j 0 −1 + j = ⎢ −2 − j2 j2 0 ⎥ = X (k, l)
⎣ 0⎦ ⎣ 0 0 0 0⎦
−1 + j −2 + j2 2 0 − j2
It is to be noted that 2-D DFT is computed using 1-D DFTs, which becomes even
simpler in the case of separable signals.
Example 4.1 Using the row–column method, find the 2-D DFT, X (k, l), of the 4 × 4
signal x(m, n).
n→
m ⎡ ⎤
1 −1 3 2
↓ ⎢2 1 2 4⎥
x(m, n) = ⎢
⎣ 1 −1 2 −2 ⎦
⎥
3 1 2 2
Multiplying x(m, n) by the left transform matrix yields the 1-D DFT of the columns.
⎡ ⎤⎡ ⎤
7+ j0 0+ j0 9+ j0 6+ j0 1 1 1 1
⎢ 0+ 0+ 1+ 4− j2 ⎥ ⎢ j⎥
⎢ j1 j0 j0 ⎥ ⎢ 1 − j −1 ⎥
⎣ −3 + j0 −4 + j0 1+ j0 −6 + j0 ⎦ ⎣ 1 −1 1 −1 ⎦
0− j1 0+ j0 1+ j0 4+ j2 1 j −1 − j
90 4 Two-Dimensional DFT
Multiplying partially transformed signal matrix by the right transform matrix yields
the 1-D DFT of the rows, and hence, the 2-D DFT of x(m, n).
l→
k ⎡ ⎤
22 + j0 −2 + j6 10 + j0 −2 − j6
↓ ⎢ 5− j1 1 + j5 −3 + j3 −3 − j3 ⎥
X (k, l) = ⎢
⎣ −12 +
⎥
j0 −4 − j2 8+ j0 −4 + j2 ⎦
5+ j1 −3 + j3 −3 − j3 1 − j5
Computing the 2-D IDFT of X (k, l) using the row–column method yields x(m, n).
However, the 1-D DFT algorithm can be used to reconstruct x(m, n). One of the
methods is to swap the real and imaginary parts of X (k, l) and compute the 2-D DFT
of the resulting matrix using the row–column method. By swapping the real and
imaginary parts of the 2-D DFT and dividing by 16 yields x(m, n). The advantage
is that no separate IDFT algorithm is required.
Swapping the real and imaginary parts of X (k, l), we get
⎡ ⎤
0 + j22 6− j2 0 + j10 −6 − j2
⎢ −1 + j5 5+ j1 3 − j3 −3 − j3 ⎥
⎢ ⎥
⎣ 0 − j12 −2 − j4 0 + j8 2 − j4 ⎦
1 + j5 3− j3 −3 − j3 −5 + j1
Swapping the real and imaginary parts and dividing by 16, we get back x(m, n).
To reduce the dynamic range of X (k, l), the display of log10 (1 + |X (k, l)|) is used
instead of |X (k, l)|. This improves the contrast of the spectrum. For the example
signal, the magnitude of the spectrum, |X (k, l)|, in the center-zero format, is
4.1 Two-Dimensional DFT as Two Sets of 1-D DFTs 91
⎡ ⎤
8 4.4721 12 4.4721
⎢ 4.2426 5.0990 5.0990 4.2426 ⎥
⎢ ⎥
⎣ 10 6.3246 22 6.3246 ⎦
4.2426 4.2426 5.0990 5.0990
–1.00–j 0.41 –1.00–j 0.41 –1.00–j 0.41 –1.00–j 0.41 –0.41+j 5.24 –4.12+j 1.29 3.71+j 5.36 –2.12+j 6.54
0.00–j 2.00 0.00+j 0.00 2.00+j 0.00 8.00+j 4.00 –2.00–j 4.00 0.00–j 3.00 0.00+j 1.00 5.00+j 1.00
–1.00–j 2.41 –1.00–j 2.41 –1.00–j 2.41 –1.00–j 2.41 2.41+j 3.24 0.12–j 2.71 2.29+j 7.36 2.12+j 0.54
93
94
Table 4.6 The magnitude of the 2-D DFT, |X (k, l)|, of x(m, n) in the center-zero format
32 9.9320 15.2971 13.0137 26 13.0137 15.2971 9.9320
9.9320 2.3431 2.3994 13.2428 18.1606 11.0737 9.5506 17.2311
14.7648 2.3994 20.3961 6.9848 13.3417 3.7739 13.4164 9.5506
13.0137 14.8535 6.9848 13.6569 3.1928 13.9674 3.7739 8.7962
18 20.1193 17.0294 21.1474 88 21.1474 17.0294 20.1193
13.0137 8.7962 3.7739 13.9674 3.1928 13.6569 6.9848 14.8535
14.7648 9.5506 13.4164 3.7739 13.3417 6.9848 20.3961 2.3994
9.9320 17.2311 9.5506 11.0737 18.1606 13.2428 2.3994 2.3431
Table 4.7 The magnitude of the 2-D DFT of x(m, n) in the center-zero format and in the log scale,
log10 (1 + |X (k, l)|)
1.5185 1.0387 1.2121 1.1466 1.4314 1.1466 1.2121 1.0387
1.0387 0.5242 0.5314 1.1536 1.2824 1.0818 1.0233 1.2608
1.1977 0.5314 1.3303 0.9023 1.1566 0.6789 1.1589 1.0233
1.1466 1.2001 0.9023 1.1660 0.6225 1.1751 0.6789 0.9911
1.2788 1.3247 1.2560 1.3453 1.9494 1.3453 1.2560 1.3247
1.1466 0.9911 0.6789 1.1751 0.6225 1.1660 0.9023 1.2001
1.1977 1.0233 1.1589 0.6789 1.1566 0.9023 1.3303 0.5314
1.0387 1.2608 1.0233 1.0818 1.2824 1.1536 0.5314 0.5242
It is easier to interpret the 2-DFT as two sets of 1-D DFTs and it is usually computed
using 1-D DFTs. Formally, the 2-D DFT of a N × N signal x(m, n) is defined as
N −1
N −1
x(m, n)e− j N (mk+nl) , k, l = 0, 1, . . . , N − 1.
2π
X (k, l) = (4.2)
m=0 n=0
As in the case of the 1-D IDFT, the 2-D IDFT synthesizes the 2-D signal by multi-
plying the basis signals with the respective coefficients and summing the samples at
all points (m, n). The 2-D IDFT is given by
N −1 N −1
1
X (k, l)e j N (mk+nl) , m, n = 0, 1, . . . , N − 1.
2π
x(m, n) = 2 (4.3)
N k=0 l=0
In this definition, the DC coefficient X (0, 0) is placed in the top left-hand corner of
the coefficient matrix. While this format is mostly used for computational purposes,
placing X (0, 0) in the center of the coefficient matrix is desired for better visualization
4.2 The 2-D DFT and IDFT 97
of the spectrum. Further, it is easier to derive some derivations using this form. This
form, called the center-zero format, with N even, is given as
2 −1 2 −1
N N
N N N
x(m, n)e− j N (mk+nl) , k, l = −
2π
X (k, l) = , − + 1, . . . , − 1
2 2 2
m=− N2 n=− N2
2 −1
2 −1
N N
1 N N N
X (k, l)e j N (mk+nl) , m, n = − , − + 1, . . . , − 1
2π
x(m, n) = 2
N N N
2 2 2
k=− 2 l=− 2
One format of the signal or the spectrum can be obtained from the other by swapping
the quadrants of the signal or spectrum in the other format.
The 2-D DFT and IDFT definitions for a M × N signal are
−1
N
M−1 k
− j2π m M +n Nl
X (k, l) = x(m, n)e , k = 0, 1, . . . , M − 1, l = 0, 1, . . . , N − 1
m=0 n=0
(4.4)
M−1 N −1
1 k
j2π m M +n Nl
x(m, n) = X (k, l)e , m = 0, 1, . . . , M − 1, n = 0, 1, . . . , N − 1
MN
k=0 l=0
(4.5)
Let us compute the 2-D DFT of the 2 × 4 signal x(m, n),
1 3 2 4
x(m, n) =
2 1 3 4
The 2-D DFT is obtained by computing the 1-D DFT of either of the partial transforms
in the other direction.
20 −2 + j4 −4 −2 − j4
X (k, l) =
0 − j2 −4 j2
98 4 Two-Dimensional DFT
The DFT, with complex exponential basis signals, is inherently designed for complex-
valued signals. However, in practice, most of the signals are real-valued. For real-
valued signals, the DFT coefficients always occur as complex conjugate pairs or real
values. Coefficients
N N N N
X (0, 0), X , 0 , X 0, ,X ,
2 2 2 2
of a N × N real-valued signal are real-valued, as the basis functions are of the form
1 and (−1)n . The rest are complex conjugate pairs. For example,
2π
2|X (k, l)| cos (mk + nl) + ∠(X (k, l))
N
= X (k, l)e j N (mk+nl) + X ∗ (k, l)e− j N (mk+nl)
2π 2π
Using Eq. (4.3), with N even, a real-valued N × N signal can be expressed as a sum
its constituent sinusoidal surfaces.
1 N
x(m, n) = 2 X (0, 0) + X , 0 cos(πm)
N 2
N N N
+ X 0, cos(πn) + X , cos(π(m + n))
2 2 2
2 −1
N
2π
+2 |X (k, 0)| cos mk + ∠(X (k, 0))
k=1
N
2 −1
N
2π
+2 |X (0, l)| cos nl + ∠(X (0, l))
l=1
N
2 −1
N
N 2π N N
+2 |X , l | cos m + nl + ∠ X ,l
l=1
2 N 2 2
4.3 The 2-D DFT of Real-Valued Signals 99
N −1
2 −1
N
2π
+2 |X (k, l)| cos (mk + nl) + ∠(X (k, l)) ,
k=1 l=1
N
m, n = 0, 1, . . . , N − 1 (4.6)
Therefore,
N2
+2
2
different sinusoidal surfaces constitute a N × N real-valued signal. The compu-
tational complexity of computing the 2-D DFT from the definition is O(N 4 ). By
computing the 2-D DFT using the row–column method, the complexity is reduced
to O(N 3 ). Fast algorithms are available for computing the 1-D DFT for lengths
those are an integral power of 2. Using these algorithms, along with the row–column
method, the computational complexity is reduced to O(N 2 log2 N ). For real-valued
2-D signals, the computational complexity can be further reduced, as presented in
Chap. 10.
Properties of the 2-D DFT relate the characteristics of signals in the spatial and
frequency domains. The DFT of signals can be computed easily using the properties
and the DFT of related simpler signals.
Linearity
Let x(m, n) ↔ X (k, l) and y(m, n) ↔ Y (k, l). Then,
where a and b are real or complex constants. The 2-D DFT of a linear combination
of a set of discrete signals is equal to the same linear combination of their individual
DFTs. The dimensions of the signals must be same. If necessary, zero padding can be
employed to meet this constraint. Linearity holds in both the spatial and frequency
domains.
Example 4.2 Compute the DFT of x(m, n) and y(m, n). Using the linearity prop-
erty, deduce the DFT of z(m, n) = 2x(m, n) + 3y(m, n) from those of x(m, n) and
y(m, n).
2 3 1 3
x(m, n) = , y(m, n) =
1 2 2 1
100 4 Two-Dimensional DFT
Solution
The individual DFTs are
8 −2 7 −1
X (k, l) = , Y (k, l) =
2 0 1 −3
The DFT of
7 15
z(m, n) = 2x(m, n) + 3y(m, n) =
8 7
is
37 −7
Z (k, l) = 2X (k, l) + 3Y (k, l) =
7 −9
The DFT Z (k, l) can be verified by directly computing that of z(m, n).
Periodicity
If x(m, n) and X (k, l) are a M × N -point DFT pair, then
where a and b are arbitrary integers and M and N are the periods. For example, the
periodic extension of signal x(m, n) in Example 4.2 is
⎡ ⎤
..
⎢ . ⎥
⎢ 2 3 2 3 2 3 ⎥
⎢ ⎥
⎢ 1 2 1 2 1 2 ⎥
⎢ ⎥
⎢... 2 3 2 3 2 3 ...⎥
⎢ ⎥
⎢ 1 2 1 2 1 2 ⎥
⎢ ⎥
⎢ 2 3 2 3 2 3 ⎥
⎢ ⎥
⎢ 1 2 1 2 1 2 ⎥
⎣ ⎦
..
.
The bottom and top edges are considered adjacent and so are the left and right edges.
Circular Shift of a Signal
A right (left) shift of a sinusoid results in adding a negative (positive) phase angle.
The change in phase is proportional to its frequency. Its magnitude is unaffected. For
a N × N signal,
N −1
N −1
x(m − m 0 , n − n 0 )e− j N (mk+nl)
2π
=
m=0 n=0
N −1
N −1
= e− j N (km 0 +ln 0 ) x(m − m 0 , n − n 0 )e− j N ((m−m 0 )k+(n−n 0 )l)
2π 2π
m=0 n=0
− j 2π
N (km 0 +ln 0 )
=e X (k, l)
Example 4.3 Using the shift theorem, find the 2-D DFT of the shifted version x(m −
2, n + 1) of the signal x(m, n) in Example 4.1. Verify that by computing the DFT
of the shifted signal.
Solution
For a 4 × 4 signal, a right shift by 2 sample intervals of the signal with frequency
index 1 contributes a phase of −180◦ . A left shift by one sample interval contributes
a phase of 90◦ . Therefore, the 2-D DFT of the shifted signal
⎡ ⎤ ⎡ ⎤
1 −1 3 2 −1 2 −2 1
⎢2 1 2 4⎥ ⎢ 1 2 2 3⎥
x(m, n) = ⎢ ⎥
⎣ 1 −1 2 −2 ⎦ x(m − 2, n + 1) = ⎢
⎣ −1
⎥
3 2 1⎦
3 1 2 2 1 2 4 2
is
⎡ ⎤
22 −6 − j2 −10 −6 + j2
⎢ −5 + j1 5 − j1 −3 + j3 3 − j3 ⎥
(−1)k ( j)l X (k, l) = ⎢
⎣
⎥ , k = 0, 1, 2, 3, l = 0, 1, 2, 3
−12 2 − j4 −8 2 + j4 ⎦
−5 − j1 3 + j3 −3 − j3 5 + j1
Example 4.4 By multiplying the signal of Example 4.1 with (−1)(m+n) , we get
⎡ ⎤
1 1 3 −2
⎢ −2 1 −2 4⎥
(−1)(m+n) x(m, n) = ⎢
⎣ 1
⎥
1 2 2⎦
−3 1 −2 2
102 4 Two-Dimensional DFT
By computing the DFT of this signal, the center-zero spectrum of x(m, n) is obtained.
⎡ ⎤
8 −4 + j2 −12 −4 − j2
⎢ −3 − j3 1 − j5 5 + j1 −3 + j3 ⎥
X (k − 2, l − 2) = ⎢
⎣
⎥
10 −2 − j6 22 −2 + j6 ⎦
−3 + j3 −3 − j3 5 − j1 1 + j5
N −1
N −1
y(m, n) = x( p, q)h(m − p, n − q), m, n = 0, 1, . . . , N − 1
p=0 q=0
Convolution of two 2-D signals, as in the case of 1-D signals, in the spatial-domain
becomes pointwise multiplication of their DFT coefficients in the frequency-domain.
This is due to the fact that convolution is a linear operation and the frequency of a
signal is unaffected from the input to the output of a LTI system.
Solution
The DFT of x(m, n) is
⎡ ⎤
22 + j0 −2 + j6 10 + j0 −2 − j6
⎢ 5− j1 1 + j5 −3 + j3 −3 − j3 ⎥
X (k, l) = ⎢
⎣ −12 +
⎥
j0 −4 − j2 8+ j0 −4 + j2 ⎦
5+ j1 −3 + j3 −3 − j3 1 − j5
4.4 Properties of the 2-D DFT 103
N −1 N −1
1
x(m, n)h(m, n) ↔ X ( p, q)H (k − p, l − q)
N 2 p=0 q=0
To find the circular convolution of X (k, l) and Y (k, l), we compute the respective
DFTs, find their pointwise product, and compute the IDFT. The results are
104 4 Two-Dimensional DFT
8 −12 −4 12 −32 −144 −7 7
, , ,4
4 8 8 4 32 32 −15 7
N −1
N −1
r xh (m, n) = x( p, q)h( p − m, q − n) ↔ H ∗ (k, l)X (k, l)
p=0 q=0
Since h(N − m, N − n) ↔ H ∗ (k, l), this operation can also be interpreted as the
convolution of x(m, n) and h(N − m, N − n).
N −1
N −1
X (0, 0) = x(m, n)
m=0 n=0
106 4 Two-Dimensional DFT
With N even,
N −1
N −1
N N
X , = x(m, n)(−1)(m+n)
2 2 m=0 n=0
N −1 N −1
1
x(0, 0) = X (k, l)
N 2 k=0 l=0
With N even,
N −1 N −1
N N 1
x , = X (k, l)(−1)(k+l)
2 2 N 2 k=0 l=0
The Difference
Reversal Property
If x(m, n) and X (k, l) form a transform pair, then so are x(N − m, N − n) and
X (N − k, N − l).
Symmetry
As a pair of complex conjugate exponentials form a real sinusoid, the exponential
Fourier representation of real-valued data is conjugate symmetric. The N × N DFT
of a real-valued data can also have only N × N independent values. The redundancy
in the transform neither increases the storage requirements nor the computational
complexity significantly with an appropriate implementation of the transform.
The DFT values at diametrically opposite points form complex conjugate pairs.
X * (N − k, N − l) = X (k, l)
Example 4.7 Underline the left-half of the nonredundant DFT values of the signal
in Example 4.1.
Solution
l→
⎡ ⎤
k 22 −2 + j6 10 −2 − j6
↓⎢⎢ 5 − j1 1 + j5 −3 + j3 −3 − j3 ⎥
⎥
⎢ ⎥
⎢ −12 −4 − j2 8 −4 + j2 ⎥
⎣ ⎦
5 + j1 −3 + j3 −3 − j3 1 − j5
Storing only the nonredundant part of the DFT coefficients, the storage require-
ment is the same as that of the input signal. The storage of the 2-D DFT values of
columns (rows) 1 to N2 − 1 and the first N2 + 1 values of the zeroth and the N2 th
columns (rows) is sufficient. The computation of the DFT requires the computation
of N2 − 1 1-D DFT of complex-valued data and N + 2 1-D DFT of real-valued data.
Rotation
The rotation of a N × N signal by an angle θ, about its center, rotates its spectrum
also by the same angle and in the same direction. Rotations other than multiples
of 90◦ require interpolation. The rotation of a 2-D signal is a part of geometric
transformations. The equations governing the counterclockwise rotation of a vector
with coordinates (m, n) by an angle θ are
The length r of the vector remains the same. In matrix notation, we get
mr cos(θ) − sin(θ) m
=
nr sin(θ) cos(θ) n
where (mr, nr ) are the new coordinates. For clockwise rotation, change the sign of
the angle.
With x(m, n) ↔ X (k, l), the rotated version of the 2-D DFT pair by θ is given by
Consider the following signal, its rotated version by 90◦ in the counterclockwise
direction and their spectra.
1̌ 2 10 −2 24 −2 0
x(m, n) = ↔ , ↔
3 4 −4 0 1̌ 3 10 −4
mr cos(90◦ ) − sin(90◦ ) m 0 −1 m −n
= = =
nr sin(90◦ ) cos(90◦ ) n 1 0 n m
The periodic extension of signal x(m, n) and its rotated version about (0, 0) are
⎡ ⎤ ⎡ ⎤
.. ..
⎢ . ⎥ ⎢ . ⎥
⎢ ⎥ ⎢ ⎥
⎢ 1 2 1 2 1 1 ⎥ ⎢ 1 3 1 3 1 3 ⎥
⎢ ⎥ ⎢ ⎥
⎢ 3 4 3 4 3 4 ⎥ ⎢ 2 4 2 4 2 4 ⎥
⎢ ⎥ ⎢ ⎥
⎢... 1 2 1̌ 2 1 2 ...⎥ ⎢... 1 3 1̌ 3 1 3 ...⎥
x p (m, n) = ⎢ ⎥ xr p (m, n) = ⎢ ⎥
⎢ 3 4 3 4 3 4 ⎥ ⎢ 2 4 2 4 2 4 ⎥
⎢ ⎥ ⎢ ⎥
⎢ 1 2 1 2 1 1 ⎥ ⎢ 1 3 1 3 1 3 ⎥
⎢ ⎥ ⎢ ⎥
⎢ 3 4 3 4 3 4 ⎥ ⎢ 2 4 2 4 2 4 ⎥
⎣ ⎦ ⎣ ⎦
.. ..
. .
The element at the origin is indicated by a check mark. For rotation other than about
the center, translation operation can be used in addition.
Separable Signals
The 2-D DFT is a separable function in the variables m and n. Therefore, the DFT
of a separable function x(m, n) = x(m)x(n) is also separable. The product of the
column vector with the row vector is equal to the 2-D function. That is,
N −1
N −1 N −1
N −1
x(m, n)e− j N mk e− j N nl = x(m)x(n)e− j N mk e− j N nl
2π 2π 2π 2π
X (k, l) =
m=0 n=0 m=0 n=0
N −1 N −1
− j 2π − j 2π
= x(m)e N mk x(n)e N nl = X (k)X (l)
m=0 n=0
Example 4.8 Compute the DFT of x(m) = {1, 3, 2, 1} and x(n) = {2, 1, 1, 3}. Using
the separability theorem, verify that the product x(m, n) = x(m)x(n) of the column
vector x(m) and the row vector x(n) in the time-domain and the 2-D IDFT of the
product of their individual DFTs are the same.
Solution
The product x(m, n) = x(m)x(n) is
⎡ ⎤ ⎡ ⎤
1 2 1 1 3
⎢3 ⎥ ⎢6 3 3 9⎥
⎢ ⎥ 2 1 1 3 =⎢ ⎥
⎣2 ⎦ ⎣4 2 2 6⎦
1 2 1 1 3
X (k) = {7, −1 − j2, −1, −1 + j2} and X (l) = {7, 1 + j2, −1, 1 − j2}.
⎤ ⎡
7
⎢−1 − j2⎥
X (k, l) = X (k)X (l) = ⎢
⎣
⎥ 7 1 + j2 −1 1 − j2
−1⎦
−1 + j2
⎡ ⎤
49 7 + j14 −7 7 − j14
⎢−7 − j14 3 − j4 1 + j2 −5⎥
=⎢⎣
⎥
−7 −1 − j2 1 −1 + j2⎦
−7 + j14 −5 1 − j2 3 + j4
Parseval’s Theorem
This theorem implies that the signal power can also be computed from the DFT
representation of the signal. Let x(m, n) ↔ X (k, l) with the dimensions of the signal
N × N . Since the magnitude of the samples of the complex sinusoidal surface
e j N (mk+nl) , m = 0, 1, . . . , N − 1, n = 0, 1, . . . , N − 1
2π
110 4 Two-Dimensional DFT
is one and the 2-D DFT coefficients are scaled by N 2 , the power of a complex
sinusoidal surface is
|X (k, l)|2 |X (k, l)|2
4
N2 =
N N2
Therefore, the sum of the powers of all the components of a signal yields the power
of the signal.
N −1
N −1 N −1 N −1
1
|x(m, n)|2 = 2 |X (k, l)|2
m=0 n=0
N k=0 l=0
For the signal x(m, n) in Example 4.2, the power computed in both the domains is
18.
The generalized form of this theorem holds for two different signals as given by
N −1
N −1 N −1 N −1
1
x(m, n)y * (m, n) = X (k, l)Y * (k, l)
m=0 n=0
N 2 k=0 l=0
4.5 Summary
Exercises
4.1 The 2-D discrete signal x(m, n) is periodic with period 4 samples in m and n.
Find its complex exponential form and thereby find its 2-D DFT coefficients X (k, l).
Verify that the samples are the same from the two forms.
* 4.1.1
2π π 2π π
x(m, n) = 2 − 3 cos (m + n) + + sin (2m + n) +
4 6 4 3
4.1.2
2π π 2π π
x(m, n) = 1 + 2 sin (m + n) − − sin (2m + n) −
4 3 4 4
4.1.3
2π π 2π
x(m, n) = −3 − 2 sin (m + n) + − 3 cos 2 (m + n)
4 3 4
4.2 Find the 2-D DFT X (k, l) of the signal x(m, n) using the row–column method.
The origin of x(m, n) is at the top left corner. Find the 2-D IDFT of X (k, l) to get
back x(m, n). Verify Parseval’s theorem.
* 4.2.1 ⎡ ⎤
2 4 2 3
⎢0 2 3 4⎥
x(m, n) = ⎢ ⎣4 2 3 1⎦
⎥
2 1 3 4
4.2.2 ⎡ ⎤
3 1 4 2
⎢1 1 2 2⎥
x(m, n) = ⎢
⎣3
⎥
3 2 2⎦
4 1 2 3
4.2.3 ⎡ ⎤
1 2 3 4
⎢4 2 1 3⎥
x(m, n) = ⎢
⎣4
⎥
3 1 2⎦
3 3 0 1
4.3 Find the DFT of the 4 × 4 signal x(m, n) using the row–column method. Each
image is composed of a shifted impulse. Verify the DFT using the shift theorem in
the spatial domain.
112 4 Two-Dimensional DFT
4.3.1 ⎡ ⎤
0 0 0 0
⎢0 0 0 0⎥
⎢
x(m, n) = ⎣ ⎥
0 1 0 0⎦
0 0 0 0
4.3.2 ⎡ ⎤
0 0 0 0
⎢0 0 0 0⎥
x(m, n) = ⎢
⎣0
⎥
0 1 0⎦
0 0 0 0
* 4.3.3 ⎡ ⎤
0 0 0 0
⎢0 0 0 0⎥
x(m, n) = ⎢
⎣0
⎥
0 0 0⎦
0 1 0 0
4.4 Using the DFT and IDFT, find: (a) the periodic convolution of x(m, n) and
h(m, n), (b) the periodic correlation of x(m, n) and h(m, n), and h(m, n) and x(m, n),
(c) the autocorrelation of x(m, n).
4.4.1 ⎡ ⎤ ⎡ ⎤
2 0 1 3 0 1 3 2
⎢3 0 4 2⎥ ⎢ 1 3 1 −2 ⎥
x(m, n) = ⎢ ⎥ ⎢
⎣ 3 1 0 1 ⎦ h(m, n) = ⎣ 3 0 2 −1 ⎦
⎥
2 0 0 2 2 0 2 2
* 4.4.2 ⎡ ⎤ ⎡ ⎤
1 2 3 4 0 3 1 2
⎢3 0 1 2⎥ ⎢1 1 1 −1 ⎥
x(m, n) = ⎢
⎣1
⎥ h(m, n) = ⎢ ⎥
1 −1 3 ⎦ ⎣2 1 0 0⎦
0 1 2 3 3 1 1 2
4.4.3 ⎡ ⎤ ⎡ ⎤
1 1 3 3 1 0 2 4
⎢ −1 0 0 4⎥ ⎢3 1 0 2⎥
x(m, n) = ⎢
⎣ 1
⎥ h(m, n) = ⎢ ⎥
1 0 2⎦ ⎣1 1 0 2⎦
2 1 0 4 0 1 −2 1
Chapter 5
Convolution and Correlation
Practical systems are analyzed using mathematical models. Convolution and transfer
function are two of the frequently used models in the study of LTI systems. In this
chapter, we study the convolution operation and we study the transfer function in
later chapters. Both the models are based on decomposing an arbitrary input signal in
terms of well-defined basis signals, impulse in the case of convolution and complex
exponential signals in the case of transfer function. After the decomposition of the
input signal, the system output can be found using the response of the system to
the basis signals and the linearity and time-invariance properties of the LTI systems.
Convolution operation relates the input and output of a system through its impulse
response. The impulse response of a system is its response to the unit-impulse signal,
assuming that the system is initially relaxed (zero initial conditions). Convolution
expresses the output of a system in terms of its input only.
The important concepts, such as convolution and Fourier analysis, are easier to
understand and remember through their physical interpretations. Convolution oper-
ation is the same thing as finding the current balance for our deposits in a bank.
Assuming compound interest, the interest is computed on the principal at regular
intervals and it is added to the principal. Let the interval be one year and the interest
rate per year be 10%. Let n = 0 be the starting time and the deposit made at that time
is designated as x(0). Then, x(n) is the deposit made after the nth year. Assuming N
number of years, the deposits are
Alternately,
After time reversing and shifting one of the two sequences, the output is the sum
of the product of the corresponding terms. The time-reversal is required, as each
other’s index is running in opposite directions. The generalization of this problem is
the convolution operation. In system analysis, the interest rate is called the impulse
response of the system. The deposits are called the input. The balance at intervals is
the output.
5.1 Convolution
The impulse response, which characterizes the system in the time domain, is the
response of a relaxed (initial conditions are zero) system for the unit-impulse δ(n).
A discrete unit-impulse signal is defined as
1, for n = 0
δ(n) =
0, for n = 0
It is an all-zero sequence, except that its value is one when its argument n is equal to
zero. The input x(n) is decomposed into a sum of scaled and delayed unit-impulses.
The response to each impulse is found and the superposition summation of all the
responses is the system output. Convolution can also be considered as the weighted
average of sections of one of the inputs with the weighting sequence being the other
input.
In the convolution operation, the input x(n) is decomposed into scaled and delayed
impulses. At each point, the contribution of all the impulses is summed to find the
5.1 Convolution 115
Let the impulse response of the system be h(n). Then, due to the time-invariance
of the LTI system, the response to a delayed impulse δ(n − k) is h(n − k). Due to
the linearity of the LTI system, the response to x(k)δ(n − k) is x(k)h(n − k) and
the total response of the system is the sum of the contributions to all the scaled and
shifted impulses. The 1-D linear convolution of two aperiodic sequences x(n) and
h(n), again due to linearity, is defined as
∞
∞
y(n) = x(k)h(n − k) = h(k)x(n − k) = x(n) ∗ h(n) = h(n) ∗ x(n)
k=−∞ k=−∞
The convolution operation relates the input x(n), the output y(n), and the impulse
response h(n) of a system.
Figure 5.1 shows the convolution of the signal x(n) = {2̌, 1, 3, 4} and h(n) =
{1̌, −2, 3}.
The output y(0), from the definition, is
where h(0 − k) is the time-reversal of h(k). Shifting h(0 − k) to the right, we get the
remaining outputs as
As can be seen from the figure, the convolution operation consists of repeatedly
executing the following four operations. The first operation is the time-reversal of
one of the sequences. The second operation is shifting. The time-reversal and shifting,
resulting in h(n − k), is relatively more difficult to visualize. It is easier to visualize
the simple shifting operation resulting in h(k − n). Since (n − k) is the same as
−(k − n), it is the time-reversal of h(k − n) about a vertical line at the point k = n.
The third operation is to find the products of the overlapping values of x(k) and
h(n − k). The fourth operation is to sum the products, which yields y(n). There are
two quick checks of the convolution output. The product of the sums of the two
sequences convolved is equal to the sum of the output sequence.
The same test after changing the signs of the odd-indexed terms is
The coefficients of the product polynomial are the same as those obtained by con-
volving x(n) and h(n).
Linear Convolution Using the DFT
A measure of the comparison of two algorithms is the order of time complexity.
For example, if the number of major operations required to execute an algorithm is
5.1 Convolution 117
proportional to N , the number of elements in the input, then its time complexity is
O(N ). The time complexity of the direct convolution operation is O(N 2 ), whereas that
using the DFT is O(N log2 N ). The evaluation of the convolution of two sequences
becomes faster for longer sequence lengths, if it is carried out in the frequency
domain. The linear convolution output of convolving two sequences is of length that is
equal to the sum of the lengths of the sequences minus one. Therefore, the sequences
have to be zero padded so that their lengths satisfy this constraint to implement
convolution using the DFT. Further, as practically used fast DFT algorithms are of
lengths that is an integral power of 2, this becomes the second constraint. Another
constraint is that the origin of the sequences must be aligned.
Let the sequences to be linearly convolved be
ˇ 11, 20, 8, 8}
{3, 10,
The lengths of the sequences are 4 and 3. Therefore, the convolution output has to
be of length 4 + 3 − 1 = 6. As there are 6 independent values in the output, the
length of the DFT must be at least of length 6. The nearest power of 2 is 23 = 8.
Therefore, the sequences are appended by zeros to make the sequences of length 8.
This excess length produces 8 − 6 = 2 zeros at the end of the output. Then, the
sequences become
The origins of the two sequences must be aligned. Circularly shifting the second
sequence by one position left, we get
{1̌, 2, 0, 0, 0, 0, 0, 3}
ˇ 0.29 − j6.95, −1 + j1, 1.71 − j2.95, −4, 1.71 + j2.95, −1 − j1, 0.29 + j6.95}
X (k) = {10,
H (k) = {6̌, 4.54 + j0.71, 1 + j1, −2.54 + j0.71, −4, −2.54 − j0.71, 1 − j1, 4.54 − j0.71}
ˇ 6.24 − j31.31, −2, −2.24 + j8.69, 16, −2.24 − j8.69, −2, 6.24 + j31.31}
X (k)H (k) = {60,
ˇ 11, 20, 8, 8, 0, 0, 3}
{10,
118 5 Convolution and Correlation
Y (k) =
x(n) xz(n) X(k) X(k)H(k) y(n) = x(n) ∗ h(n)
zero pad DFT IDFT
H(k)
DFT
hz(n)
zero pad
h(n)
Circularly shifting right by one sample interval, we get the linear convolution output
appended by 2 zeros.
ˇ 11, 20, 8, 8, 0, 0}
y(n) = {3, 10,
Figure 5.2 shows the block diagram for implementing linear convolution using
the DFT. The sequences to be convolved, x(n) and h(n), are sufficiently zero padded
according to the requirements given earlier to get xz(n) and hz(n). The DFT of the
zero-padded sequences is computed to get, X (k) and H (k). The IDFT of the term-
by-term product, X (k)H (k), of the DFTs yields the linear convolution of x(n) and
h(n) with some zeros appended. If necessary, alignment of the sequences must be
taken care of, as already pointed out.
The circular convolution is also known as cyclic or periodic convolution. While the
linear convolution is used most of the times in the analysis of LTI systems, the circular
convolution is also important for the reason that signals are considered as periodic in
DFT computation and the DFT is the tool to implement the linear convolution faster.
The linear convolution is the periodic convolution in the limit, when the periods of the
signals to be convolved become infinite. Both the circular and linear convolution are
based on the same four operations (folding, shifting, multiplication, and summing).
The difference is that the folding and shifting operations are carried out along a line
in the linear convolution, whereas it is carried out around a circle in the circular
convolution. Due to this difference, some number of output values of linear and
circular convolutions, for the same inputs, are different at the borders.
The circular convolution of the two sequences x(n) and h(n), both of period N , is
defined as
5.1 Convolution 119
N −1
N −1
y(n) = x(m)h(n − m) = h(m)x(n − m), n = 0, 1, . . . , N − 1
m=0 m=0
resulting in the periodic output sequence y(n) with the same period. Consider the
circular convolution output y(n) of the sequences
ˇ −8, 9, 3}
y(n) = {16,
shown in Fig. 5.3. This is the same as the linear convolution with the sequences
periodic. Consequently, the first three output values are different from that of the
linear convolution and the fourth value is the same. The linear convolution output
y(n) of the same sequences is
The last three values get added to the first three values to form the circular convolution
output. The sum of the shifted, by 4 samples, copies of linear convolution output is the
circular convolution output. In circular convolution, the periods of the two sequences
to be convolved are assumed to be the same. Let x(n) is a sequence of length N and
h(n) is a sequence of length M with M ≤ N . Sequence h(n) is zero padded to make
its length also N . Then, the circular convolution of x(n) and h(n) yields N output
values. The first (M − 1) output values are not the corresponding linear convolution
output values, while the rest of the (N − M + 1) values are the same. In the last
example, with N = M = 4, the last value y(3) = 3 only is the same in both the
outputs.
Overlap–Save Method
In practical applications, the input sequence is often very long and the impulse
response is relatively short. Even if the required memory is available, the output will
be delayed too long. In these cases, due to the limited availability of the memory
in digital systems and the desirability of fast output, the input signal is segmented
into blocks to suit the memory availability and the speed of response. Each block is
120 5 Convolution and Correlation
1 2 −1 3 0 0 0 0
1 2 −1 3 0 0 0 0
y(n) 2 5 −3 3 14 −13 12
convolved with the impulse response and the convolution outputs of the successive
blocks are assembled to form the total convolution output. There are two equivalent
methods to carry out convolution in this way. One of it, called the overlap–save
method, is described.
The overlap–save method of convolution of long sequences is shown in Fig. 5.4.
Let the length of the input sequence x(n) be N . Let the length of the impulse response
h(n) be Q and the block length be B. Then, for efficient implementation of the method,
the following condition should be met.
N >> B >> Q
For illustrative purposes, short sequences are used in the example. Let x(n) and h(n)
be
x(n) = {2̌, 1, −3, 4} and h(n) = {1̌, 2, −1, 3}
Therefore, there are N + Q − 1 = 7 output values have to be computed. Let the block
length B be 8 and N = Q = 4. As first Q − 1 = 3 output values are corrupted, the
input data has to be prepended by 3 zeros. Since the block length B is 8, the data has to
be appended by one zero. The first block of extended x(n) is {0, 0, 0, 2, 1, −3, 4, 0}.
The DFT of this block, with a precision of 2 digits, is
{4, −0.29 + j0.46, −3 + j5, −1.71 − j7.54, 6, −1.71 + j7.54, −3 − j5, −0.29 − j0.46}
The extended h(n) is {1, 2, −1, 3, 0, 0, 0, 0}. The DFT of this data, which is com-
puted only once and stored, is
{5, 0.29 − j2.54, 2 + j1, 1.71 − j4.54, −5, 1.71 + j4.54, 2 − j1, 0.29 + j2.54}
{20, 1.09 + j0.88, −11 + j7, −37.09 − j5.12, −30, −37.09 + j5.12, −11 − j7, 1.09 − j0.88}
5.1 Convolution 121
The last five values {2, 5, −3, 3, 14} are the first five values of linearly convolving
x(n) and h(n). The second block has to overlap the first block by 3 samples. Therefore,
the second block is {−3, 4, 0, 0, 0, 0, 0, 0}. The DFT of this block, with a precision
of 2 digits, is
{1, −0.17 − j2.83, −3 − j4, −5.83 − j2.83, −7, −5.83 + j2.83, −3 + j4, −0.17 + j2.83}
The last five values {−13, 12, 0, 0, 0} are the last two values of linearly convolving
x(n) and h(n) appended by three zeros.
The same four steps of the 1-D convolution (folding, shifting, multiplying, and sum-
ming) are repeatedly carried out in implementing the 2-D convolution in two dimen-
sions.
1. Any one of the two sequences, say h(k, l), is rotated in the (k, l) plane by 180◦
about the origin to get h(−k, −l). Of course, the same result is achieved by folding
122 5 Convolution and Correlation
h(k, l) about the k-axis to get h(k, −l) and then folding h(k, −l) about the l-axis
to get h(−k, −l) or vice versa.
2. The rotated sequence h(−k, −l) is shifted by (m, n) to get h(m − k, n − l) to find
the convolution output at coordinates (m, n).
3. The term-by-term products, x(k, l)h(m − k, n − l), of all the overlapping samples
are computed.
4. Summing all the products is the convolution output y(m, n) at (m, n).
Let us find the output of convolving the 3 × 3 sequence h(k, l) and the 4 × 4
sequence x(k, l)
⎡ ⎤
⎡ ⎤ 3̌ 1 3 2
2̌ 1 3 ⎢2
⎢ 1 3 4⎥⎥
h(k, l) = ⎣ 1 2 2 ⎦ and x(k, l) = ⎣
2 1 2 3⎦
3 2 1
1 1 2 2
shown in Fig. 5.5. Four examples of computing the convolution output are shown.
For example, with a shift of (0 − k, 0 − l), there is only one overlapping pair (3, 2).
The product of these numbers is the output y(0, 0) = 6. The process is repeated to
get the complete convolution output y(m, n) shown in the figure.
We assumed that the values outside the defined region of the sequence are zero.
This assumption may or may not be suitable. Some other commonly used border
extensions are based on periodicity, symmetry, or replication.
Let us compute the linear convolution of the last example using the DFT. As the
convolution output is of size 6 × 6 and the nearest power of 2 is 8, the sequences are
zero padded to get
⎡ ⎤ ⎡ ⎤
3̌ 1 3 2 0 0 0 0 2̌ 1 3 0 0 0 0 0
⎢2 1 3 4 0 0 0 0⎥ ⎢1 2 2 0 0 0 0 0⎥
⎢ ⎥ ⎢ ⎥
⎢2 1 2 3 0 0 0 0⎥ ⎢3 2 1 0 0 0 0 0⎥
⎢ ⎥ ⎢ ⎥
⎢1 1 2 2 0 0 0 0⎥⎥ ⎢0 0 0 0 0 0 0 0⎥
xz(m, n) = ⎢
⎢0 ⎥ hz(m, n) = ⎢
⎢0
⎥
⎢ 0 0 0 0 0 0 0⎥ ⎢ 0 0 0 0 0 0 0⎥⎥
⎢0 0 0 0 0 0 0 0⎥⎥ ⎢0 0 0 0 0 0 0 0⎥
⎢ ⎢ ⎥
⎣0 0 0 0 0 0 0 0 ⎦ ⎣0 0 0 0 0 0 0 0⎦
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
The 2-D DFT of xz(m, n), X (k, l), is shown in Table 5.1. The 2-D DFT of hz(m, n),
H (k, l), is shown in Table 5.2. The pointwise product of X (k, l) and H (k, l),
X (k, l)H (k, l) is shown in Table 5.3. The IDFT of X (k, l)H (k, l) is the convolu-
tion output y(m, n) appended by zeros in the last 2 rows and columns.
⎡ ⎤
6 5 16 10 11 6 0 0
⎢ 7 11 24 24 23 16 0 0 ⎥
⎢ ⎥
⎢ 15 18 34 36 30 19 0 0 ⎥
⎢ ⎥
⎢ 10 15 29 37 29 16 0 0 ⎥
y(m, n) = ⎢
⎢ 7 10 16 22 16 7 0 0 ⎥
⎥
⎢ ⎥
⎢ 3 5 9 11 6 2 0 0 ⎥
⎢ ⎥
⎣ 0 0 0 0 0 0 0 0⎦
0 0 0 0 0 0 0 0
⎡ ⎤ ⎡ ⎤
1̌ 1 1 1
h(m, n) = ⎣ 1 1 1 ⎦ = ⎣ 1 ⎦ 1 1 1 = h(m)h(n)
1 1 1 1
The convolution of x(m, n) given in the last example with this filter can be carried
out using two 1-D filters, {h(0) = 1, h(1) = 1, h(2) = 1}. Since xz(m, n) is of size
8 × 8, the zero-padded filter is
5.1 Convolution
Table 5.3 Convolution output Y (k, l) = X (k, l)H (k, l) in the frequency domain
561.00+j 0.00 −167.41−j225.58 35.00+j10.00 33.41+j30.42 21.00+j 0.00 33.41−j30.42 35.00−j10.00 −167.41+j225.58
−71.38−j296.96 −87.96+j130.00 −10.54−j37.51 13.95−j 1.12 14.12−j 8.12 −25.78−j34.95 −7.12−j 7.12 132.76+j56.58
−20.00−j 5.00 4.07+j 2.00 −8.00+j 9.00 2.17−j 0.59 6.00−j 3.00 −10.07+j 2.00 2.00−j 1.00 7.83−j 3.41
23.38+j 7.04 4.05−j 3.12 −2.88+j 2.88 3.96+j10.00 9.88+j 3.88 1.24−j 1.42 −3.46−j 3.51 −10.22+j25.05
7.00+j 0.00 14.66−j 4.00 3.00−j 4.00 3.34+j 4.00 15.00+j 0.00 3.34−j 4.00 3.00+j 4.00 14.66+j 4.00
23.38−j 7.04 −10.22−j25.05 −3.46+j 3.51 1.24+j 1.42 9.88−j 3.88 3.96−j10.00 −2.88−j 2.88 4.05+j 3.12
−20.00+j 5.00 7.83+j 3.41 2.00+j 1.00 −10.07−j 2.00 6.00+j 3.00 2.17+j 0.59 −8.00−j 9.00 4.07−j 2.00
−71.38+j296.96 132.76−j56.58 −7.12+j 7.12 −25.78+j34.95 14.12+j 8.12 13.95+j 1.12 −10.54+j37.51 −87.96−j130.00
125
126
Table 5.4 Partial convolution output P(k, l) = X (k, l)H (k) in the frequency domain
99 9.15−j61.82 −6.00+j21.00 38.85−j1.82 9.00+j0.00 38.85+j1.82 −6.00−j21.00 9.15+j61.82
−12.78−j53.16 −30.56+j4.83 14.78−j1.71 −4.83−j18.90 5.12−j5.12 −2.41−j25.31 −9.95+j6.54 34.97−j14.07
−4.00−j1.00 0.12+j0.71 −1.00−j2.00 −0.71+j0.12 0.00−j3.00 −4.12−j0.71 1.00+j2.00 0.71−j4.12
2.78+j0.84 0.83−j0.90 −0.05+j0.54 0.56+j0.83 0.88+j0.88 1.03−j0.07 −0.78+j0.29 0.41+j2.69
1.00+j0.00 2.71+j0.71 2.00−j1.00 1.29+j0.71 3.00+j0.00 1.29−j0.71 2.00+j1.00 2.71−j0.71
2.78−j0.84 0.41−j2.69 −0.78−j0.29 1.03+j0.07 0.88−j0.88 0.56−j0.83 −0.05−j0.54 0.83+j0.90
−4.00+j1.00 0.71+j4.12 1.00−j2.00 −4.12+j0.71 0.00+j3.00 −0.71−j0.12 −1.00+j2.00 0.12−j0.71
−12.78+j53.16 34.97+j14.07 −9.95−j6.54 −2.41+j25.31 5.12+j5.12 −4.83+j18.90 14.78+j1.71 −30.56−j4.83
5 Convolution and Correlation
5.1 Convolution 127
Table 5.5 Convolution output Y (k, l) = P(k, l)H (l) in the frequency domain
297 −89.91− 21.00+j6.00 11.91+j10.85 9.00+j0.00 11.91−j10.85 21.00−j6.00 −89.91+
j121.15 j121.15
−38.33− −43.92+ −1.71− 4.12−j6.95 5.12−j5.12 −8.12−j6.71 −6.54−j9.95 83.72+j35.68
j159.49 j60.41 j14.78
−12.00− 1.41+j1.00 −2.00+j1.00 −0.24−j0.17 0.00−j3.00 −1.41+j1.00 −2.00+j1.00 8.24−j5.83
j3.00
8.33+j2.51 −0.12−j2.95 0.54+j0.05 −0.08+j0.41 0.88+j0.88 0.28−j0.32 −0.29−j0.78 −3.88+j5.29
3.00+j0.00 5.83−j3.41 −1.00−j2.00 0.17+j0.59 3.00+j0.00 0.17−j0.59 −1.00+j2.00 5.83+j3.41
8.33−j2.51 −3.88−j5.29 −0.29+j0.78 0.28+j0.32 0.88−j0.88 −0.08−j0.41 0.54−j0.05 −0.12+j2.95
−12.00+ 8.24+j5.83 −2.00−j1.00 −1.41−j1.00 0.00+j3.00 −0.24+j0.17 −2.00−j1.00 1.41−j1.00
j3.00
−38.33+ 83.72−j35.68 −6.54+j9.95 −8.12+j6.71 5.12+j5.12 4.12+j6.95 −1.71+ −43.92−
j159.49 j14.78 j60.41
The row and column filters have the same coefficients. Taking the 1-D DFT of this
filter, we get
The 2-D DFT, X (k, l), of xz(m, n) is shown in Table 5.1. The partial convolution out-
put, P(k, l) = X (k, l)H (k) shown in Table 5.4, in the frequency domain is obtained
by pointwise multiplication of each column of X (k, l) by H (k). The convolution out-
put, Y (k, l) = P(k, l)H (l) shown in Table 5.5, in the frequency domain is obtained
by pointwise multiplication of each row of P(k, l) by H (l). The output is the 2-D
IDFT of Y (k, l).
⎡ ⎤
3 4 7 6 5 2 0 0
⎢ 5 7 13 14 12 6 0 0 ⎥
⎢ ⎥
⎢ 7 10 18 20 17 9 0 0 ⎥
⎢ ⎥
⎢ 5 8 15 19 16 9 0 0 ⎥
⎢
y(m, n) = ⎢ ⎥
⎥
⎢ 3 5 9 11 9 5 0 0 ⎥
⎢1 2 4 5 4 2 0 0⎥
⎢ ⎥
⎣0 0 0 0 0 0 0 0⎦
0 0 0 0 0 0 0 0
The top-left 6×6 of y(m, n) are the output values. Figure 5.6 shows the block diagram
for 2-D convolution with separable filters. The filter is decomposed in to row and col-
umn filters with sufficient zero padding and their DFTs H (l) and H (k) are computed.
The input x(m, n) is zero padded to get xz(m, n) and its DFT X (k, l) is computed.
The columns of X (k, l) are multiplied by H (k) to get the partial convolution output
128 5 Convolution and Correlation
H(k) H(l)
1-D DFT 1-D DFT
hz(m) hz(n)
Decompose
hz(m, n)
Fig. 5.6 2-D linear convolution using the DFT with separable filters
P(k, l) = X (k, l)H (k) in the frequency domain. The rows of partial convolution out-
put P(k, l) are multiplied by H (l) to get the convolution output Y (k, l) = P(k, l)H (l)
in the frequency domain. The 2-D IDFT of Y (k, l) is the convolution output y(m, n).
5.2 Correlation
Correlation is a similarity measure between two signals. The correlation output indi-
cates the strength of the relationships between the signals, which may be negative,
zero or positive. If the signals are positively correlated, then both increase or decrease
together. The more time we walk, the more calories we burn. If the signals are neg-
atively correlated, then one increases and the other decreases. It is an inverse rela-
tionship. An increase in the amount of physical effort results in weight loss. Zero
correlation implies no discernible relationship between the two variables. If a signal
increases with the other remaining constant or increasing half the time and decreas-
ing half the time, it indicates no correlation. In signal processing, object recognition
and estimation are typical examples of correlation operation. The most famous and
important example, of course, is the determination of the amplitudes of the signal
components by correlating the given signal with each of its components in Fourier
analysis.
The cross-correlation of two signals x(n) and y(n) is defined as
∞
∞
∗
rxy (m) = x(n)y (n − m) = x(n + m)y∗ (n), m = 0, ±1, ±2, . . .
n=−∞ n=−∞
Equivalent but alternate definition is also used. The asterisk in the definition indicates
complex conjugation operation, which has no effect for real-valued signals. The
5.2 Correlation 129
output is the sum of products of two signals, with one of them shifted. The number
of shifts is the independent variable and the sum is the dependent variable.
The correlation of y(n) = {2̌, 1, −3} and x(n) = {2̌, 1, 3, 4} is shown in Fig. 5.7.
The output is rxy (n) = {−6, −1, −4̌, −7, 10, 8}. The convolution operation without
time-reversal is the correlation operation. Convolution of the time-reversed version
of the sequence y(n) with x(n) is the same as correlation of x(n) and y(n). Two real
signals x(n) and y(n) are said to be orthogonal over the entire time interval if
∞
x(n)y(n) = 0
n=−∞
When two signals to be correlated are the same, the operation is called autocorre-
lation. The autocorrelation function of real-valued signals is even-symmetric. Unlike
convolution, correlation operation, in general, is not commutative. The correlation
of a function with an impulse shifts the time-reversed version of the function to the
location of the impulse.
Let us implement the correlation using the DFT. The zero-padded 8-point DFTs,
X (k) and Y (k), of x(n) and y(n) are, respectively,
5.3 Applications
Large number of applications are based on Fourier analysis, correlation, and convo-
lution. In this section, we present some samples of the applications.
Filter is a system that removes something from whatever passes through it. A coffee
filter removes the coffee grounds and allows the decoction to flow through. A water
filter removes salt and bacteria. An ultraviolet filter blocks or absorbs ultraviolet
light.
In signal and image processing, the spectra of signals are altered in a desired
way. If the low-frequency components are allowed and high-frequency components
suppressed, it is called a lowpass filter. If the high-frequency components are allowed
and low-frequency components suppressed, it is called a highpass filter. If we find
the running averages of a set of numbers in a neighborhood of a number of a long
data sequence, the bumpiness of the sequence is reduced. On the other hand, if we
find the differences, the bumpiness will be enhanced and the smoothness reduced. A
purely high frequency signal such as {1, −1} will become zero, if averaged. A purely
low-frequency signal such as {1, 1} will become zero, if differenced. The filtering
operation, in the time domain, is modeled by convolution. The impulse responses of
the various types of filters characterize the filtering action.
The filtering operation is easier to visualize in the frequency domain, since con-
volution in the time domain becomes multiplication in the frequency domain. The
spectrum of a signal is a display of its ordered frequency components versus their
respective amplitudes. Therefore, we can simply alter any part of the spectrum in a
desired way. If we make the coefficients of the high-frequency components of the
signal small or zero, the signal becomes smoother. If we make the coefficients of the
low-frequency components of the signal small or zero, the signal becomes bumpier.
In addition to easier visualization of the filtering operation, the implementation of
the filtering operation in the frequency domain is faster for longer filters. Let us study
the filtering operation in both the time domain and the frequency domain.
Lowpass filters with different characteristics are available. The impulse response
of the simplest and widely used 3 × 3 2-D lowpass filter, called the averaging filter,
is
5.3 Applications 131
⎡ ⎤
h(−1, −1) h(−1, 0) h(−1, 1)
h(m, n) = ⎣ h(0, −1) h(0.0) h(0, 1) ⎦
h(1, −1) h(1, 0) h(1, 1)
⎡ ⎤
1 1 1
1
= ⎣ 1 1 1 ⎦ , m = −1, 0, 1, n = −1, 0, 1
9 1 1 1
The origin of the filter is shown in boldface. All the coefficient values are 1/9. The
filter outputs the average of the pixel values of the image in each neighborhood.
Variable weighting is applied in other lowpass filters. When an image is passed
through this filter, the output at each point is given by
1
y(m, n) = (x(m − 1, n − 1) + x(m − 1, n) + x(m − 1, n + 1) + x(m, n − 1) + x(m, n)
9
+ x(m, n + 1) + x(m + 1, n − 1) + x(m + 1, n) + x(m + 1, n + 1))
The output image becomes smoother. The smoothing effect increases with larger
filters.
When a 2-D filter is decomposable in terms of 1-D filters, it is always advantageous
to use 1-D convolution to filter an image. The averaging filter is decomposable. This
filter can be expressed as the product of a the 3×1 column filter hc (m) = {1, 1, 1}T /3
and the 1 × 3 row filter hr (n) = {1, 1, 1}/3, which is the transpose of the column
filter. ⎡ ⎤ ⎡ ⎤
1 1 1 1
1⎣ 1 1
h(m, n) = 1 1 1⎦ = ⎣1⎦ 1 1 1 = hc (m)hr (n)
9 1 1 1 3 1 3
The filtered output is obtained by convolving the image with the column filter first and
then convolving the partial output by the row filter or vice versa, as convolution oper-
ation is commutative. With the 2-D filter h(m, n) separable, h(m, n) = hc (m)hr (n)
and, with input x(m, n),
In filtering images, suitable border extensions are assumed. Assuming zero padding
at the borders, the output of 1-D filtering of the columns of the input and the output
of 1-D filtering of the rows of the partial output are, respectively,
⎡ ⎤ ⎡ ⎤
3 −1 7 4 2 9 10 11
1⎢ 5 −3 8 3⎥ 1 ⎢ 2 10 8 11 ⎥
yc(m, n) = ⎢ ⎥ y(m, n) = ⎢ ⎥
3 ⎣4 −3 2 2⎦ 9 ⎣1 3 1 4⎦
3 −1 −1 1 2 1 −1 0
Note that, only the central part of the output, of the same size as the input, is shown.
Assuming periodicity at the borders, the extended input and the output are, respec-
tively,
⎡ ⎤
2 1 1 −2 2 1 ⎡ ⎤
⎢ 3 2 1 4 3 2⎥ 10 9 11 15
⎢ ⎥
⎢ 1 1 −2 3 1 1⎥ 1 ⎢ 5 10 8 16 ⎥
xe(m, n) = ⎢
⎢ −1
⎥ y(m, n) = ⎢ ⎥
⎢ 2 −2 1 −1 2 ⎥
⎥ 9 ⎣ 3 3 1 8⎦
⎣ 2 1 1 −2 2 1⎦ 9 8 7 12
3 2 1 4 3 2
With different border extensions, the outputs differ only at the borders.
Figure 5.8a shows a 256 × 256 8-bit gray level image. Figure 5.8b–d shows the
filtered images with 5 × 5, 9 × 9 and 13 × 13 averaging filters, respectively. The
blurring of the image is more with the larger filters.
Lowpass Filtering with the DFT
For a 2-D signal, we have to zero pad in two directions. Figure 5.9 shows the 8 × 8
zero-padded image xz(m, n), obtained from the 4 × 4 image x(m, n) used in the last
example. The 3 × 3 filter h(m, n), along with the corresponding zero-padded and
shifted row and column filters, is also shown. Since the convolution output is of size
is 6 × 6 and the the nearest power of 2 is 8, the size of the zero-padded image is
8 × 8.
As the averaging filter is separable. the convolution operation can be carried out
using two 1-D filters, {h(−1) = 1, h(0) = 1, h(1) = 1}/3. Since xz(m, n) is of size
8 × 8 and the origin is at the top-left corner, the zero-padded filter has to be of length
8 with h(0) in the beginning. The zero-padded filter can be written as
1
hz(m) = {1, 1, 0, 0, 0, 0, 0, 1}
3
with the origin at the beginning, by circularly shifting left by one position, The row
filter, shown in Fig. 5.9, is the transpose of the column filter. Computing the 1-D DFT
5.3 Applications 133
Fig. 5.8 a A 256 × 256 8-bit image; b filtered image with 5 × 5 averaging filter; c filtered image
with 9 × 9 filter; d filtered image with 13 × 13 filter
Fig. 5.9 Zero padding of images for implementing the 2-D linear convolution using the 2-D DFT
134 5 Convolution and Correlation
Since the filter is real-valued and even-symmetric in the time domain, its DFT is
also real-valued and even-symmetric, The DFT of the column filter H (k) is the
transpose of that of the row filter H (l). The 2-D DFT, X (k, l), of xz(m, n) in Fig. 5.9
is shown in Table 5.6. The partial convolution output, 3P(k, l) = X (k, l)H (l) shown
in Table 5.7, in the frequency domain is obtained by pointwise multiplication of each
row of X (k, l) by H (l). The convolution output, 9Y (k, l) = 3P(k, l)H (k) shown in
Table 5.8, in the frequency domain is obtained by pointwise multiplication of each
column of 3P(k, l) by H (k).
The 2-D IDFT of 9Y (k, l) divided by 9 is the output, which is the same as that
obtained by time-domain convolution, is
⎡ ⎤
2 9 10 11 4 0 0 3
⎢ 2 10 8 11 3 0 0 5 ⎥
⎢ ⎥
⎢1 3 1 4 2 0 0 4⎥
⎢ ⎥
1 ⎢ 2 1 −1 0 1 0 0 3 ⎥
y(m, n) = ⎢ ⎥
9⎢⎢2 0 1 0 2 0 0 1⎥ ⎥
⎢0 0 0 0 0 0 0 0⎥
⎢ ⎥
⎣0 0 0 0 0 0 0 0⎦
3 7 8 7 3 0 0 2
The top left 4 × 4 of y(m, n) are the center part of the output of the linear convolution
of x(m, n) and h(m, n).
Figure 5.10a shows the magnitude spectrum in log scale, log10 (1 + |X (k, l)|) in
the center-zero format, of the image in Fig. 5.8a. Figure 5.10b–d shows the magnitude
spectra in log scale of the 5 × 5, 9 × 9 and 13 × 13 averaging filters, respectively. As
with the characteristics of typical practical images, the spectrum of the image has
high magnitude in the neighborhood of zero frequency and the magnitude decreases
with increasing frequency. A small filter has a less blurring effect and is characterized
by a high cutoff frequency. As the size of the filter increases, the cutoff frequency
moves toward zero frequency and the blurring effect is more pronounced.
Table 5.7 Partial convolution output 3P(k, l) = X (k, l)H (l) in the frequency domain
45.00+j0.00 2.54−j19.61 0.00+j7.00 –4.54–j1.61 –9.00+j0.00 –4.54+j1.61 0.00–j7.00 2.54+j19.61
32.12−j10.61 −2.41−j21.90 –1.71+j1.71 –3.00–j0.24 –8.36+j6.71 –0.66+j5.31 –9.36–j5.12 0.41+j18.49
30.00−j3.00 −6.95−j15.78 –1.00+j6.00 –3.54+j1.39 4.00+j9.00 2.95–j0.22 –5.00+j4.00 3.54+j22.61
27.88−j10.61 −3.00−j8.24 3.36+j0.88 0.41+j2.10 4.36–j5.29 –2.41–j1.51 –0.29–j0.29 10.66+j17.31
15.00+j0.00 6.54−j7.95 –2.00–j1.00 –0.54–j1.95 –7.00+j0.00 –0.54+j1.95 –2.00+j1.00 6.54+j7.95
27.88+j10.61 10.66−j17.31 –0.29+j0.29 –2.41+j1.51 4.36+j5.29 0.41–j2.10 3.36–j0.88 –3.00+j8.24
30.00+j3.00 3.54−j22.61 –5.00–j4.00 2.95+j0.22 4.00–j9.00 –3.54–j1.39 –1.00–j6.00 –6.95+j15.78
32.12+j10.61 0.41−j18.49 –9.36+j5.12 –0.66–j5.31 –8.36–j6.71 –3.00+j0.24 –1.71–j1.71 –2.41+j21.90
5 Convolution and Correlation
5.3 Applications
Table 5.8 Convolution output 9Y (k, l) = 3P(k, l)H (k) in the frequency domain
135.00+j0.00 7.61–j58.82 0.00+j21.00 –13.61–j4.82 –27.00+j0.00 –13.61+j4.82 0.00–j21.00 7.61+j58.82
77.55–j25.61 –5.83–j52.87 –4.12+j4.12 –7.24–j0.59 –20.19+j16.19 –1.59+j12.83 –22.61–j12.36 1.00+j44.63
30.00–j3.00 –6.95–j15.78 –1.00+j6.00 –3.54+j1.39 4.00+j9.00 2.95–j0.22 –5.00+j4.00 3.54+j22.61
–11.55+j4.39 1.24+j3.41 –1.39–j0.36 –0.17–j0.87 –1.81+j2.19 1.00+j0.63 0.12+j0.12 –4.41–j7.17
–15.00+j0.00 –6.54+j7.95 2.00+j1.00 0.54+j1.95 7.00+j0.00 0.54–j1.95 2.00–j1.00 –6.54–j7.95
–11.55–j4.39 –4.41+j7.17 0.12–j0.12 1.00–j0.63 –1.81–j2.19 –0.17+j0.87 –1.39+j0.36 1.24–j3.41
30.00+j3.00 3.54–j22.61 –5.00–j4.00 2.95+j0.22 4.00–j9.00 –3.54–j1.39 –1.00–j6.00 –6.95+j15.78
77.55+j25.61 1.00–j44.63 –22.61+j12.36 –1.59–j12.83 –20.19–j16.19 –7.24+j0.59 –4.12–j4.12 –5.83+j52.87
137
138 5 Convolution and Correlation
Fig. 5.10 a The magnitude spectrum in log scale, log10 (1 + |X (k, l)|) in the center-zero format,
of the image in Fig. 5.8a; b the magnitude spectrum in log scale of the 5 × 5 averaging filter; c the
magnitude spectrum in log scale, of the 9 × 9 averaging filter; and d the magnitude spectrum in log
scale of the 13 × 13 averaging filter
Using this filter, with the same input used for lowpass filtering, the outputs with the
input zero padded are
⎡ ⎤
8 1 13 10
⎢ 3 −13 11 0⎥
y(m, n) = ⎢
⎣ 10 −12
⎥
7 −9 ⎦
2 8 −14 13
5.3 Applications 139
Fig. 5.11 a Image in Fig. 5.8a after application of the 4 × 4 Laplacian sharpening filter (Eq. (5.1));
b image in Fig. 5.8a after application of a 8 × 8 Laplacian sharpening filter
Figure 5.11a shows the image in Fig. 5.8a after application of the 4 × 4 Laplacian
filter (Eq. (5.1)). Figure 5.11b shows the image in Fig. 5.8a after application of the
8 × 8 Laplacian sharpening filter. The edges are sharper compared with Fig. 5.11a.
Image Sharpening with the DFT
High-frequency signals are characterized by the high difference between successive
sample values. In this section, we present image sharpening with the DFT for the
same input and the filter, assuming zero padding at the borders. The sharpening filter
is inseparable with the center in the middle. By zero padding and shifting in two
directions, we get
⎡ ⎤
5 −1 0 0 0 0 0 −1
⎢ −1 0 0 0 0 0 0 0⎥
⎢ ⎥
⎢ 0 0 0 0 0 0 0 0⎥
⎢ ⎥
⎢ 0 0 0 0 0 0 0 0⎥
hz(m, n) = ⎢
⎢ 0
⎥
⎢ 0 0 0 0 0 0 0⎥⎥
⎢ 0 0 0 0 0 0 0 0⎥
⎢ ⎥
⎣ 0 0 0 0 0 0 0 0⎦
−1 0 0 0 0 0 0 0
The 2-D DFT, H (k, l), of hz(m, n) is shown in Table 5.9. Since the filter is real-valued
and even-symmetric, its DFT is also real-valued and even-symmetric. The 2-D DFT
of the zero-padded input X (k, l) is the same as in the last example. The convolution
140 5 Convolution and Correlation
output Y (k, l) = X (k, l)H (k, l), in the frequency domain, is obtained by pointwise
multiplication and it is shown in Table 5.10. The output, which is the same as that
obtained in in the spatial domain, is the top left 4 × 4 of the 8 × 8 2-D IDFT of Y (k, l)
⎡ ⎤
8 1 13 10
⎢ 3 −13 11 0⎥
y(m, n) = ⎢
⎣ 10 −12
⎥
7 −9 ⎦
2 8 −14 13
The differences between this version and cross-correlation are: (i) the correlation
is computed using the local mean-subtracted versions of the two inputs and (ii) the
output is normalized to the range −1–1. One consequence is that the template cannot
be composed of uniform values. The correlation coefficient is assigned the value zero,
if the variance of the image over the overlapping portion with the template is zero.
The higher the value of the coefficients, the better is the match between the template
and the image. The fluctuating part of the values of the inputs is used in computing
the correlation. The numerator is cross-correlation with the means subtracted. The
denominator is a normalizing factor. It is the square root of the product of the variances
of the overlapping samples of the inputs.
Consider the computation of the cross-correlation coefficients between x(m, n)
and y(m, n).
5.3 Applications
Table 5.10 Convolution output Y (k, l) = X (k, l)H (k, l) in the frequency domain
15.00+j0.00 1.67–j12.88 0.00+j21.00 48.33+j17.12 45.00+j0.00 48.33–j17.12 0.00–j21.00 1.67+j12.88
16.98–j5.61 –2.17–j19.70 –6.12+j6.12 36.21+j2.93 46.72–j37.46 7.93–j64.14 –33.58–j18.36 0.37+j16.63
30.00–j3.00 –10.32–j23.44 –5.00+j30.00 54.75–j21.58 –28.00–j63.00 –45.68+j3.44 –25.00+j20.00 5.25+j33.58
41.02–j15.61 –6.21–j17.07 21.58+j5.64 –7.83–j39.70 –36.72+j44.54 45.63+j28.63 –1.88–j1.88 22.07+j35.86
25.00+j0.00 15.12–j18.39 –14.00–j7.00 10.88+j39.61 63.00+j0.00 10.88–j39.61 –14.00+j7.00 15.12+j18.39
41.02+j15.61 22.07–j35.86 –1.88+j1.88 45.63–j28.63 –36.72–j44.54 –7.83+j39.70 21.58–j5.64 –6.21+j17.07
30.00+j3.00 5.25–j33.58 –25.00–j20.00 –45.68–j3.44 –28.00+j63.00 54.75+j21.58 –5.00–j30.00 –10.32+j23.44
16.98+j5.61 0.37–j16.63 –33.58+j18.36 7.93+j64.14 46.72+j37.46 36.21–j2.93 –6.12–j6.12 –2.17+j19.70
141
142 5 Convolution and Correlation
⎡ ⎤
⎡ ⎤ 2 1 4 3
2 1 3 ⎢ 1 −2 3 1⎥
y(m, n) = ⎣ 1 1 −2 ⎦ x(m, n) = ⎢
⎣ 2 −2
⎥
1 −1 ⎦
1 3 1
1 1 −2 2
The location of an object can be precisely located by correlating the image with
the template of the object. Figure 5.12a shows a 76×106 8-bit image composed of the
text ‘DISCRETE FOURIER TRANSFORM’. The problem is to locate the locations
of the letter ‘O’. The 10 × 10 8-bit template is shown in Fig. 5.12b. The two brightest
points in Fig. 5.12c show the thresholded correlation coefficients image obtained by
correlating the image with the template. The two points clearly indicate the locations
of the letter ‘O’ in the image. The output is just 2 pixels. For clear visibility, they
have been dilated. The un-normalized correlation output between the image and the
template, shown in Fig. 5.12d, does not point out the locations of the letter ‘O’ in the
image.
Fig. 5.12 a A 76 × 106 8-bit image; b 10 × 10 8-bit template of the letter ‘O’; c the thresholded
and dilated correlation coefficients image; d the un-normalized correlation output
144 5 Convolution and Correlation
∼ ∼
3 cos(πn) 3 cos(πn)
∼ ∼
cos( π2 n+ π6 ) cos( π2 n + π6 )
∼ ∼
2 2
With a complex coefficient, we are able to modulate the amplitude and phase of a
sinusoid or, equivalently, the amplitudes of the in-phase and quadrature components
of a sinusoid. As it is easier to implement, the quadrature form is used in practice.
Note that, in OFDM, the subcarriers are orthogonal and their frequencies are fixed.
With X (0) = 2+j1 and X (1) = 1+j2, these coefficients correspond to the frequency
components
2π 2π
x0 (n) = (2 + j1)e 2 0n
= 2 + j1 and x1 (n) = (1 + j2)e 2 1n
= (1 + j2) cos(π n)
Let us say we want to transmit 4 messages, AA, AB, BA, and BB. Let 1 + j2
represent the symbol A and 2+j1 represent the symbol B. Then, the real and imaginary
components of the modulated signals corresponding to the 4 messages, AA, AB, BA,
and BB, are shown in Figs. 5.14 and 5.15, respectively.
(a) (b)
2 3
xrAA(n)
xrAB(n)
0 -1
0 1 0 1
n n
(c) (d)
3 4
xrBA(n)
xrBB(n)
1 0
0 1 0 1
n n
Fig. 5.14 Real components of the modulated subcarriers corresponding to different messages,
a AA, b AB, c BA, and d BB
5.3 Applications 147
(a) 4 (b) 3
xiAA (n)
xiAB (n)
0 1
0 1 0 1
n n
(c) 3 (d) 2
xiBA (n)
xiBB (n)
0
-1 0
0 1 0 1
n n
Fig. 5.15 Imaginary components of the modulated subcarriers corresponding to different messages,
a AA, b AB, c BA, and d BB
Frequedncy domain
Mapping QAM
Source Data Time domain
onto N Orthogonal Time-domain Recover mapped
Subcarriers Transmitter Sum of sinusoids Receiver QAM Source Data
IDFT DFT
2π 2π
(1 + j2)e 2 0n
+ (1 + j2)e 2 1n
= (1 + j2) + (1 + j2) cos(π n) = {2 + j4, 0 + j0} → AA
2π 2π
(1 + j2)e 2 0n
+ (2 + j1)e 2 1n
= (1 + j2) + (2 + j1) cos(π n) = {3 + j3, −1 + j1} → AB
2π 2π
(2 + j1)e 2 0n
+ (1 + j2)e 2 1n
= (2 + j1) + (1 + j2) cos(π n) = {3 + j3, 1 − j1} → BA
2π 2π
(2 + j1)e 2 0n
+ (2 + j1)e 2 1n
= (2 + j1) + (2 + j1) cos(π n) = {4 + j2, 0 + j0} → BB
The DFT of these time-domain samples is the scaled frequency coefficients input by
the transmitter.
These modulated discrete signals are converted to analog signals, also shown in
Figs. 5.14 and 5.15, by a digital to analog converter. The analog signals are modulated
by a high-frequency carrier for the purpose of transmission and transmitted. At the
receiver, these signals are demodulated to get the baseband signal and the DFT
yields the message. Figure 5.16 shows the essence of transmitting and receiving
messages using OFDM. The input data is mapped to quadrature data, assumed in
the frequency domain. The IDFT of this data is a sum of sinusoids in time domain,
which is transmitted after converting to analog signal and modulating with a high
148 5 Convolution and Correlation
cos(ωc t) ∼ 2 cos(ωc t) ∼
Low-pass
re(t) x1 (t) filter re(t)
frequency. The DFT of the samples of the demodulated signal at the receiver is the
source frequency-domain data transmitted. Reversing the mapping carried out at the
transmitter, we get the input message.
Quadrature Amplitude Modulation
Quadrature amplitude modulation (QAM) transmits 2 signals using carriers of the
same frequency but in phase quadrature. Figure 5.17 shows the quadrature amplitude
modulation and demodulation. The carrier frequency is cos(ωc t). Phase shifters are
used to delay the carrier frequency to get sin(ωc t). The in-phase component of the
message signal is multiplied by cos(ωc t). The quadrature component is multiplied
by sin(ωc (t). The sum of the two product signals is the modulator output
there are 16 numbers, each subcarrier can transmit the information of log2 16 = 4
bits. There are 16 distinct combinations with 4 bits and there are 16 distinct complex
numbers. Therefore, a subcarrier, a cos(ωc t) + b sin(ωc t) transmits 4 bits.
Example—Parallel code for the message ‘Discrete Fourier Transform’ with 4 sub-
channels each of length 8.
Table 5.11 shows the 16-point QAM assignment of codes to the distinct characters in
the message. As there are less than 16 characters, the last few are assigned the code
for space.
For example, the code for ‘D’ is −3 − j1, and it is the first entry in the first
subchannel shown below. The code for ‘I’ is −1 + j3, which is the second entry
in the first subchannel. Similarly, after assigning codes for all the characters in the
message, we get
⎡ ⎤
−3 − j 1 + j3 1 + j3 1 − j3
⎢ −1 + j3 −1 + j 3 − j3 −3 + j1 ⎥
⎢ ⎥
⎢ 3 − j1 1−j 1 − j3 1 + j3 ⎥
⎢ ⎥
⎢ −1 − j3 1 + j −1 − j 1 + j3 ⎥
⎢ ⎥
⎢ 1 − j3 1 − j3 −3 + j3 1 + j3 ⎥
⎢ ⎥
⎢ −3 − j3 −1 + j3 3−j 1 + j3 ⎥
⎢ ⎥
⎣ 3 − j3 −3 − j3 −1 + j 1 + j3 ⎦
−3 − j3 1 − j3 1−j 1 + j3
These are the modulated signals in the frequency domain. We take the IDFT, which
is a sum of all the modulated sinusoids in each subchannel. The result is
150 5 Convolution and Correlation
⎡ ⎤
−0.5 − j1.8 0.0 − j0.3 0.5 − j0.3 0.5 + j2.0
⎢−1.3 + j1.1 −0.4 + j0.7 1.4 − j0.1 −0.2 − j1.3 ⎥
⎢ ⎥
⎢−1.8 + j0.0 −0.3 + j0.0 0.0 + j1.8 0.3 − j1.3 ⎥
⎢ ⎥
⎢−0.8 + j0.1 0.1 + j0.8 0.0 − j0.2 0.5 − j0.9 ⎥
⎢ ⎥
⎢ 1.5 − j0.3 0.0 − j0.8 −1.0 + j1.3 0.5 − j0.5 ⎥
⎢ ⎥
⎢−0.2 − j0.6 −0.1 + j1.8 0.6 + j0.6 0.2 − j0.2 ⎥
⎢ ⎥
⎣−0.3 + j0.0 1.3 + j1.0 −0.5 + j0.3 −0.3 − j0.3 ⎦
0.3 + j0.4 0.4 − j0.3 0.0 − j0.3 −0.5 − j0.6
For example, the real part of the first entry −0.5 is obtained as the sum of the real
part of the entries of the real parts of the first columns divided by 8.
(−3 − 1 + 3 − 1 + 1 − 3 + 3 − 3) −4
= = −0.5
8 8
Passage of the Modulated Time-Domain Signal Through the Channel
The channel has an impulse response. For this example, let us assume that it is
h(n) = {1̌, 0.3, 0.1}. The output at the end of the channel is the linear convolution
of the time-domain signal with h(n). As the time-domain signal is periodic, circular
convolution is required. Linear convolution of two sequences results in a sequence
of length that is equal to the sum of the length of the two sequences minus 1. Circular
5.3 Applications 151
convolution of two sequences of equal length results in a sequence of the same length.
Circular convolution can be used to compute the linear convolution by sufficient zero
padding of the sequences.
The partial periodic extension is called the cyclic prefix. Take the output from n = 0
to n = N − 1, where N is the length of the periodic sequences to be convolved. The
necessity for this is because the data is periodic in OFDM, while the channel carries
out linear convolution.
The periodically extended data is
⎡ ⎤
−0.3 + j0.0 1.3 + j1.0 −0.5 + j0.3 −0.3 − j0.3
⎢ 0.3 + j0.4 0.4 − j0.3 0.0 − j0.3 −0.5 − j0.6 ⎥
⎢ ⎥
⎢−0.5 − j1.8 0.0 − j0.3 0.5 − j0.3 0.5 + j2.0 ⎥
⎢ ⎥
⎢−1.3 + j1.1 −0.4 + j0.7 1.4 − j0.1 −0.2 − j1.3 ⎥
⎢ ⎥
⎢−1.8 + j0.0 −0.3 + j0.0 0.0 + j1.8 0.3 − j1.3 ⎥
⎢ ⎥
⎢−0.8 + j0.1 0.1 + j0.8 0.0 − j0.2 0.5 − j0.9 ⎥
⎢ ⎥
⎢ 1.5 − j0.3 0.0 − j0.8 −1.0 + j1.3 0.5 − j0.5 ⎥
⎢ ⎥
⎢−0.2 − j0.6 −0.1 + j1.8 0.6 + j0.6 0.2 − j0.2 ⎥
⎢ ⎥
⎣−0.3 + j0.0 1.3 + j1.0 −0.5 + j0.3 −0.3 − j0.3 ⎦
0.3 + j0.4 0.4 − j0.3 0.0 − j0.3 −0.5 − j0.6
The last 2 rows of the last matrix have been prepended resulting in 8 rows becoming
10 rows. The modulated time-domain analog data, obtained using a digita-to-analog
converter, with a prefix shown by the dotted line, is shown in Fig. 5.19. This prefixed
data is linearly convolved withe the channel impulse response h(n) = {h(0) =
1, h(1) = 0.3, h(2) = 0.1}. The result is
152 5 Convolution and Correlation
xi(n)
0 0
-0.3
-0.5
-0.8
-1.3
-1.75 -1.75
0 1 2 3 4 5 6 7 8 0 1 2 3 4 5 6 7 8
n n
Fig. 5.19 Modulated time-domain analog data with a prefix, shown by the dotted line
⎡ ⎤
−0.3 + j0.0 1.3 + j1.1 −0.2 + j0.3 −0.3 − j0.3
⎢ 0.2 + j0.4 0.8 + j0.1 −0.1 − j0.2 −0.6 − j0.7 ⎥
⎢ ⎥
⎢−0.4 − j1.6 0.3 − j0.2 0.5 − j0.3 0.3 + j1.8 ⎥
⎢ ⎥
⎢−1.4 + j0.7 −0.4 + j0.6 1.5 − j0.2 −0.1 − j0.7 ⎥
⎢ ⎥
⎢−2.2 + j0.2 −0.4 + j0.2 0.5 + j1.7 0.2 − j1.4 ⎥
⎢ ⎥
⎢−1.4 + j0.2 −0.0 + j0.9 0.1 + j0.3 0.6 − j1.4 ⎥
⎢ ⎥
⎢ 1.1 − j0.2 −0.0 − j0.5 −1.0 + j1.4 0.7 − j0.9 ⎥
⎢ ⎥
⎢ 0.2 − j0.7 −0.1 + j1.6 0.3 + j1.0 0.4 − j0.5 ⎥
⎢ ⎥
⎣−0.2 − j0.2 1.2 + j1.5 −0.4 + j0.6 −0.1 − j0.4 ⎦
0.2 + j0.4 0.8 + j0.2 −0.1 − j0.1 −0.6 − j0.7
For example,
is the real part value of the first value in the third row. The received analog signal is
passed through an analog-to-digital converter to get the sampled data.
Now, the DFT of the columns of the last 8 rows is computed resulting in
⎡ ⎤
−4.2 − j1.4 1.4 + j4.2 1.4 + j4.2 1.4 − j4.2
⎢−0.3 + j3.9 −0.9 + j1.5 2.7 − j4.6 −3.3 + j2.1 ⎥
⎢ ⎥
⎢ 2.4 − j1.8 0.6 − j1.2 −0.0 − j3.0 1.8 + j2.4 ⎥
⎢ ⎥
⎢−1.1 − j2.3 0.9 + j0.7 −0.9 − j0.7 1.1 + j2.3 ⎥
⎢ ⎥
⎢ 0.8 − j2.4 0.8 − j2.4 −2.4 + j2.4 0.8 + j2.4 ⎥
⎢ ⎥
⎢−2.0 − j2.7 −1.1 + j2.3 2.5 − j0.5 0.5 + j2.5 ⎥
⎢ ⎥
⎣ 3.6 − j1.8 −1.8 − j3.6 −1.2 + j0.6 0.0 + j3.0 ⎦
−2.7 − j4.6 2.1 − j3.3 1.5 − j0.9 0.3 + j3.9
The frequency response of the channel, H (k), is the 8-point DFT of its impulse
response h(n).
5.3 Applications 153
2 SNR = 20 dB
Im
0
-1
-2
-3
-3 -2 -1 0 1 2 3
Re
H (k) = {1.4, 1.2121 − j0.3121, 0.9 − j0.3, 0.7879 − j0.1121, 0.8, 0.7879 + j0.1121, 0.9
+ j0.3, 1.2121 + j0.3121}
1
= {0.7, 0.8 + j0.2, 1.0 + j0.3, 1.2 + j0.2, 1.3, 1.2 − j0.2, 1.0 − j0.3, 0.8 − j0.2}
H (k)
The pointwise product of each column of the DFT values by these values yields
the input message. The equalization is made simple due to orthogonality of the
subcarriers. We are getting back the exact input message because of the assumption
of zero noise.
With SNR = 20 dB, OFDM scatter plot is shown in Fig. 5.20. As noise is high,
the received signals are scattered around the exact input message. For each received
value, the input value nearest is assigned by computing the distances. To reduce the
noise, Wiener filter can be used. Further error correcting codes may recover the exact
data.
With SNR = 30 dB, OFDM scatter plot is shown in Fig. 5.21. Now, the received
values are much closer to the actual values.
With SNR = 40 dB, OFDM scatter plot is shown in Fig. 5.22. With SNR high, the
received and input values almost overlap.
The block diagram of OFDM transmission system is shown in Fig. 5.23. The
QAM mapped data in the frequency domain, coming in serial form, is converted
to parallel form. The IDFT of the parallel data is computed to get the time-domain
samples. Now, the cyclic prefix is added. This data is converted to serial analog form,
modulated by a carrier and transmitted. The distorted signal, due to the channel and
noise, is demodulated, cyclic prefix removed and converted to parallel discrete form
154 5 Convolution and Correlation
2 SNR = 30 dB
Im
0
-1
-2
-3
-3 -2 -1 0 1 2 3
Re
2 SNR = 40 dB
1
Im
-1
-2
-3
-3 -2 -1 0 1 2 3
Re
at the receiver. The analog processing is not shown in the diagram. The DFT of the
time-domain samples yields the frequency-domain data. This data is passed through
equalizer to compensate for the loss of gain in transmission through the channel. This
equalization is independently carried out for each subcarrier. The equalized signal
is passed through a detector to find the final frequency-domain data. One of the
ways of detection is to assign the data to the nearest, by Euclidean distance, QAM
constellation point. Further, scrambling for data security, error correction coding,
and coding for compression of data form part of the transmission system.
5.3 Applications 155
L Remove
Serial to Cyclic parallel to Serial to
IDFT h(k)z −k cyclic DFT Equalizer
parallel prefix serial parallel
k=0 prefix
A complex signal whose imaginary part is the Hilbert transform of its real part is
called the analytic signal. An analytic signal has no negative frequency components.
Hilbert transformer shifts the phase of every spectral component by π2 radians. Typical
applications are single sideband modulation in communication systems and sampling
of bandpass signals.
The frequency response of the Hilbert transformer, for an even N , is
⎧
⎨ −j for k = 1, 2, . . . , N2 − 1
H (k) = 0 for k = 0, N2
⎩
j for k = N2 + 1, N2 + 2, . . . , N − 1
Basically, it is an all-pass filter that imparts a ±90◦ phase shift on the input signal.
However, in practice, it is designed over the required bandwidth of a given input
signal.
The IDFT of H (k) is the impulse response. As the frequency response is imaginary
and odd-symmetric, the impulse response is real and odd.
N −1 N −1
1 j 2π j 2π
h(n) = H (k)e N kn
= H (k) sin kn
N N N
k=0 k=0
For example,
2π
x(n) = cos n ↔ X (k) = {0, 2, 0, 2},
4
H (k) = {0, −j, 0, j}, X (k)H (k) = {0, −j2, 0, j2}
Now, the analytic signal xa (n) corresponding to x(n) is the complex signal with x(n)
as its real part and xh (n) as its imaginary part.
156 5 Convolution and Correlation
2π 2π 2π
xa (n) = x(n) + jxh (n) = cos n + j sin n = ej 4 n ↔ {0, 4, 0, 0},
4 4
2π
(x(n) = {1, 0, −1, 0})
∗ ({0, 0.5, 0, −0.5} = h(n)) = {0, 1, 0, −1} = xh (n) = sin n
4
5.4 Summary
• Convolution is one of the often used system models. It relates the input and output
of a system through its impulse response. It can also be considered as the weighted
average of a signal.
• The input signal is decomposed in terms of impulses and the superposition sum-
mation of the responses of the system to all the constituent impulses is the system
output.
• In terms of computation, it is a sum of products of two sequences after time-reversal
of one of them.
• In linear convolution, the sequences are located on a line. In circular convolution,
the sequences are located on a circle. The output values differ only at the border.
• In applications, linear convolution is often required. However, with sufficient zero
padding of the sequences, linear convolution is implemented using circular con-
volution efficiently.
• The computational complexity of the 1-D convolution of sequences of length N in
the time domain is O(N 2 ), whereas the complexity is reduced to O(N log2 N ) in
the frequency domain. The reason is that convolution in the time domain becomes
multiplication in the frequency domain with complexity O(N ). Mapping a time-
domain sequence into a frequency-domain sequence requires a complexity of
O(N log2 N ).
• Points to be noted in implementing the linear convolution operation using the DFT
are: (i) the sequences must be zero padded so that their lengths are at the least equal
to the sum of the lengths of the two sequences to be convolved minus one; (ii) the
length of the zero-padded sequences is the nearest integral power of 2; and (iii)
the origins of the sequences are aligned.
5.4 Summary 157
Exercises
5.1 Find the linear convolution y(n) of x(n) and h(n), using the DFT and the IDFT.
Verify y(n) by convolving x(n) and h(n) in the time domain.
5.1.1
x(n) = {2̌, 3, 1, 4} and h(n) = {1̌, −3, 1, −4}
5.1.2
x(n) = {1̌, 1, −2, 4} and h(n) = {1̌, 2, 1, 4}
* 5.1.3
x(n) = {2̌, 1, 3, 4} and h(n) = {1̌, −2, 3, −4}
5.2 Find the linear convolution y(m, n) of x(m, n) and h(m, n), using the DFT and
the IDFT. Verify y(m, n) by convolving x(m, n) and h(m, n) in the time domain.
* 5.2.1
1 −3 2 3
x(m, n) = , h(m, n) =
1 2 −2 1
5.2.2
−2 1 3 −3
x(m, n) = , h(m, n) =
−4 2 −1 4
5.2.3
4 −3 2 2
x(m, n) = , h(m, n) =
3 −4 1 3
5.3 Find the linear correlation rxh (n) of x(n) and h(n), using the DFT and the IDFT.
Verify rxh (n) by correlating x(n) and h(n) in the time domain.
5.3.1
x(n) = {1̌, 3, 1, 4} and h(n) = {1̌, −3, 3, −4}
* 5.3.2
x(n) = {1̌, 2, −2, 4} and h(n) = {1̌, 2, −1, 4}
5.3.3
x(n) = {2̌, 1, 3, 2} and h(n) = {1̌, 2, −3, 4}
158 5 Convolution and Correlation
5.4 Find the linear correlation rxh (m, n) of x(m, n) and h(m, n), using the DFT and
the IDFT. Verify rxh (m, n) by correlating x(m, n) and h(m, n) in the time domain.
* 5.4.1
−1 −3 1 3
x(m, n) = , h(m, n) =
3 2 −3 1
5.4.2
−2 2 4 −3
x(m, n) = , h(m, n) =
−1 2 −1 3
5.4.3
2 −3 2 1
x(m, n) = , h(m, n) =
3 −1 1 −3
5.5 Find the linear Hilbert transform xh (n) of x(n). Compute the DFT of x(n)+jxh (n)
and verify that the spectrum is one-sided.
5.5.1 x(n) = {2, −3, 1, 4}.
There are four versions of the Fourier analysis. DFT is the only one that is discrete
and finite in both the domains, and, hence, implementable using a digital system. In
approximating other versions of the Fourier analysis, it has to be ensured that the
data is adequately represented by the DFT in any one period. It is possible because
physical devices can generate signals over a finite period only and can generate
frequency components of a finite order only. Therefore, the sampling interval and
the record length have to be carefully chosen. Then, for all practical purposes, all
waveforms generated by physical devices can be represented by the DFT adequately.
In this chapter, we learn how to determine the proper sampling interval and the record
length.
4 (4+1)n
2π 2π 2π 2π 2π
ej 4 5n = ej = ej 4 4n ej 4 1n = ej 4 1n
2π
The impersonation of a higher frequency exponential e j 4 5n as a lower-frequency
2π
exponential e j 4 1n , due to insufficient number of samples, is called the aliasing effect.
For complex signals, with period N , the aliasing effect is characterized by
where l is any integer. Remember that periodic signals are defined over a circle. There
are only N unique samples for a complex exponential with period N . Therefore,
Figure 6.1 shows the aliasing effect with sinusoids x(n) = cos( 2π8
n + π3 ) and
π
xa(n) = cos( 8 7n − 3 ) having the same set of samples. While their continuous
2π
versions have different amplitude profiles, as shown by the continuous and dashed
lines, their discrete versions have the same amplitude profile.
6.1 Aliasing Effect 161
x(n) 1
−1
0 1 2 3 4 5 6 7
n
π π
Fig. 6.1 Sinusoid x(n) = cos( 2π
8 n + 3 ). Sinusoid xa(n) = cos( 8 7n − 3 ) in dashed line
2π
2π π 2π π 2π π
xa(n) = cos (8 − 1)n − = cos (−1)n − = cos n+ = x(n)
8 3 8 3 8 3
If the sum or difference of the frequency indices of two discrete sinusoids is an inte-
gral multiple of the sampling period, then it is impossible to differentiate between
them. For example, a discrete waveform with period 16 samples can have distinct
frequency components with frequency indices k = {0, 1, 2, 3, 4, 5, 6, 7, 8} only. Fre-
quency component with index zero is DC and that with 8 is a cosine waveform. Fre-
quency components with frequency indices k = {16, 15, 14, 13, 12, 11, 10, 9} alias
as k = {0, 1, 2, 3, 4, 5, 6, 7}. Frequency components with frequency indices k =
{17, 18, 19, 20, 21, 22, 23, 24} alias as k = {1, 2, 3, 4, 5, 6, 7, 8}. Figure 6.2
shows the aliasing effect, which is also shown in Table 6.1. For example, the sum of
frequency indices 1 and 15 is 16 (the difference of frequencies 1 and 17 is also 16)
and it is not possible differentiate between them with the sampling frequency 1/16
cycles/sample. In general, with a sampling frequency f s cycles/sample, the formula
to find the index of the alias f a of any frequency component f is given by
Table 6.1 Frequency components with frequencies f and the corresponding aliased frequencies
with sampling frequency f s = 1/16 cycles/sample
f 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
f 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
fa 0 1 2 3 4 5 6 7 8 7 6 5 4 3 2 1
162 6 Aliasing and Leakage
f
f a = f − f s round
fs
To avoid the aliasing effect, the sampling theorem states that the sampling fre-
quency must be greater than twice that of the highest frequency component of a
real-valued signal. Given a sampling frequency, the input signal has to be prefiltered
to eliminate the frequency components with frequencies greater than or equal to half
the sampling frequency. In practice, aliasing cannot be eliminated but can be reduced
to negligible levels with appropriate choice of the sampling frequency.
In approximating signals by the DFT, due to the finite and discrete nature of the DFT,
the sampling interval and the record length have to be selected appropriately. The
aliasing effect due to insufficient number of samples over a period was presented in
the last section. Now, we are going to study the importance of selecting the appropriate
record length. The record length is usually very long and the frequency content is very
high. However, for practical signals, it is possible to approximate them adequately
due to the fact that the magnitude of signals becomes negligible in both the time
domain and the frequency domain beyond some finite range. A time-limited signal
cannot be band-limited. For practical purposes, we are able to assume that signals
are both time-limited and band-limited with adequate accuracy. For example, while
the exponential signal e−at u(t), a > 0 approaches zero asymptotically, its spectrum
can be effectively approximated by the DFT using a relatively short record length. In
digital filter design, everlasting impulse responses are suitably truncated for practical
purposes. To eliminate aliasing, the signal is prefiltered, which is spectral truncation.
The point is that truncation is inevitable and it distorts the data. However, it has to be
ensured that the representation of the signal or spectrum is still adequate for practical
purposes. The criterion for truncation is based on signal energy or amplitude. For
example, the difference between the energy of the original signal and its truncated
version is to be less than 5%.
The DFT computation assumes periodic extension of the given finite data. If a
frequency component makes an integral number of cycles in one period, then its DFT
coefficient will be an impulse at its frequency index. Otherwise, a discontinuity is
created between the first and last samples in each period. To synthesize such a signal
requires more number of frequency components. The energy of the signal is leaked
to other frequency components. In practice, leakage cannot be eliminated. To reduce
leakage, a more appropriate record length has to be selected. Once leakage occurs,
the choice is to reduce the leakage error and increase the smearing effect or vice
versa.
6.2 Leakage Effect 163
Truncation of a N -point signal x(n) to get a L-point signal x̂(n) (L < N ) may be
considered as multiplying x(n) by a rectangular window wr (n) defined as
1 for n = 0, 1, . . . , L − 1
wr (n) =
0 for n = L , L + 1, . . . , N − 1
wr (n) = {1, 1, 1, 1}
With L = N = 8,
wr (n) = {1, 1, 1, 1, 1, 1, 1, 1}
The objective is to relate the DFT of x(n) and x̂(n). The truncated signal is
the product of x(n) and wr (n). Then, due to the DFT frequency-domain circular
convolution theorem, we get
1
x̂(n) = x(n)wr (n) ↔ X̂ (k) = X (k)
∗ Wr (k)
N
and
wr (n) = {1̌, 1, 0, 0} ↔ Wr (k) = {2̌, 1 − j, 0, 1 + j}
The spectrum of the original signal is distorted due to truncation. First, more num-
ber of frequency components are required to reconstruct the signal. This is called
leakage or spectral spreading. Since the resultant spectrum is the convolution of
spectra of the signal and the window, due to a convolution property, the length of the
nonzero spectral components increases. In the aliasing effect, a set of frequencies
fold back on to a single frequency. Due to the leakage effect, a single frequency
component produces a set of frequencies. This is also similar to signal compres-
sion and expansion. The amplitude of the spectrum is reduced due to smoothing
(from X (1) = X (3) = 2 to X (1) = X (3) = 1), resulting in loss of detail. Similar to
reducing the aliasing by decreasing the sampling interval, the leakage effect can be
reduced by selecting a more appropriate record length. Once truncation has occurred,
the only alternative is to reduce the leakage at the cost of increasing the smearing
of the spectrum. To reduce the leakage, the signal has to be multiplied by a tapered
window, which truncates the signal gradually. The characteristics of some of the
often used windows are presented next.
The rectangular, triangular, Hann, and Hamming window functions are shown in
Fig. 6.3 with N = L = 32.
Rectangular Window
The rectangular window is shown by dots and its DFT is given by Eq. (6.1). Let x(n)
be a N -point sequence. Retaining only the first L samples and making the rest equal
to zero to get a truncated sequence x̂(n) are equivalent to multiplying it with the
window wr (n). That is
x̂(n) = x(n)wr (n)
1
N=32
L =32
w(n)
rectangular
o hamming
x Hann
0.08 + triangular
0
0 4 8 12 16 20 24 28 31
n
0 rectangular N=64
|W(k)/W(0)|, dB
L =16
-10
-13.339
-20
0 4 8 12 16 20 24 28
k
Fig. 6.4 The normalized magnitude in dB of the frequency response of the rectangular window
Example 6.1 List the values of the rectangular window wr (n) with N = 8 and L = 5.
Find the truncated version, xt (n), of one cycle of x(n), starting from n = 0, by
applying the window. Find the magnitude of the DFT of x(n) and xt (n).
2π
x(n) = e j 8 n , n = 0, 1, 2, 3, 4, 5, 6, 7
wr (n) = {1, 1, 1, 1, 1, 0, 0, 0}
X (k) = {0, 8, 0, 0, 0, 0, 0, 0}
The rectangular window is the best in terms of resolution and is the worst in terms
of the magnitude of the side lobes. Therefore, the rectangular window is preferred
when there is no leakage, the leakage is tolerable or if it is possible to select a more
appropriate record length that results in tolerable leakage. Otherwise, a suitable
tapered window is to be used. The truncated data is multiplied by the window so that
the data is gradually reduced to zero or near zero at the ends. These windows provide
the advantage of detection of frequency components with small magnitudes; those
may be masked by the large side lobes of the rectangular window. Several windows
are available and their suitability for specific applications is well known. The general
approach in designing a window to reduce the side lobes is to make the transition
of the signal more smoother from the middle toward the ends. The magnitude of the
side lobes of the rectangular window is relatively large, due to its discontinuity at
the ends. Therefore, its spectrum decays slowly at the rate of 1/k, where k is the
frequency index. By reducing or eliminating this discontinuity, the spectrum of the
tapered windows decays faster resulting in smaller side lobes. This is achieved at the
cost of increasing the main lobe width, which reduces resolution.
Triangular Window
The convolution of a function by itself in the time domain corresponds to the product
of its spectrum by itself in the frequency domain. Therefore, the side lobes adjacent
to the main lobes have considerably smaller magnitudes. From the time-domain
viewpoint, as the resulting function becomes smoother, the spectrum is expected to
decay at a faster rate resulting in smaller side lobes. However, the width of the function
is increased in the time domain and the width of the main lobe of the spectrum is
also increased.
The triangular window is defined as
⎧2
⎪
⎨ Ln for n = 0, 1, . . . , L2
wt (n) = wt (L − n) for n = L2 + 1, L2 + 2, . . . , L − 1
⎪
⎩
0 for n = L , L + 1, . . . , N − 1
With L = N = 8,
with itself followed by a circular right shift of one sample interval is the triangular
window with a scale factor. For example, with N = 4 and L = 2,
N
Wr2 (k) = {4, − j2, 0, j2} ↔ wt (n + 1) = {1, 2, 1, 0}
2
N N
Wr2 (k)e− j
2π
4 k = Wt (k) = {4, −2, 0, −2} ↔ wt (n) = {0, 1, 2, 1}
2 2
Therefore, simplifying, we get the DFT of an even-length triangular window as
2
2 2 2 sin( π2 k)
W (k)e− j N k =
2π
Wt (k) = e jπk
N r N sin( Nπ k)
As the time-domain function is real and even, the spectrum is also real and even.
The window is even-symmetric with the first sample value zero. For N even, the
middle value is 1. Therefore, the DFT of an even-length triangular window of length
N is also given by
2 −1
N
4n 2π
Wt (k) = (−1) +k
cos nk
n=1
N N
2
4n 2π
Wt (k) = cos nk
n=1
N N
0 triangular N=64
L =16
|W(k)/W(0)|, dB
-20
-25.913
-40
0 8 12 16 20 24 28
k
Fig. 6.5 The normalized magnitude in dB of the frequency response of the triangular window
Example 6.2 List the values of the triangular window wr (n) with N = 8 and L = 5.
Find the truncated version, xt (n), of one cycle of x(n), starting from n = 0, by
applying the window. Find the magnitude of the DFT of x(n) and xt (n).
2π
x(n) = e j 8 n , n = 0, 1, 2, 3, 4, 5, 6, 7
X (k) = {0, 8, 0, 0, 0, 0, 0, 0}
0 Hann N=64
L =16
|W(k)/W(0)|, dB
-20
-32.192
-40
-60
-80
0 4 8 12 16 20 24 28
k
Fig. 6.6 The normalized magnitude in dB of the frequency response of the Hann window
in the frequency domain requires multiplication of the window in the time domain
with a complex exponential (frequency shift theorem).
The Hann window is defined as
0.5 − 0.5 cos 2π n for n = 0, 1, . . . , L − 1
whan (n) = L
0 for n = L , L + 1, . . . , N − 1
The time-domain representation of this window is shown in Fig. 6.3 by the cross
symbol, with L = 32 and N = 32. For example, with L = N = 4,
With L = N = 8,
Therefore, the frequency response is given in terms of that of the rectangular window
as
Whan (k) = 0.5Wr (k) − 0.25Wr (k + 1) − 0.25Wr (k − 1)
The magnitude of the DFT in dB is shown in Fig. 6.6 with L = 16 and N = 64. The
magnitude of the largest side lobe is −32.192 dB.
Example 6.3 List the values of the Hann window whan (n) with N = 8 and L = 5.
Find the truncated version, xt (n), of one cycle of x(n), starting from n = 0, by
applying the window. Find the magnitude of the DFT of x(n) and xt (n).
170 6 Aliasing and Leakage
2π
x(n) = e j 8 n , n = 0, 1, 2, 3, 4, 5, 6, 7
X (k) = {0, 8, 0, 0, 0, 0, 0, 0}
The time-domain representation of this window is shown in Fig. 6.3 by unfilled circles
with L = 32 and N = 32. For example, with L = N = 4,
With L = N = 8,
The magnitude of the DFT in dB is shown in Fig. 6.7 with L = 16 and N = 64. The
magnitude of the largest side lobe is −40.160 dB.
Example 6.4 List the values of the Hamming window wr (n) with N = 8 and L = 5.
Find the truncated version, xt (n), of one cycle of x(n), starting from n = 0, by
applying the window. Find the magnitude of the DFT of x(n) and xt (n).
2π
x(n) = e j 8 n , n = 0, 1, 2, 3, 4, 5, 6, 7
6.2 Leakage Effect 171
0 hamming N=64
|W(k)/W(0)|, dB
-10 L =16
-20
-30
-40.160
-40
0 4 10 16 22 28
k
Fig. 6.7 The normalized magnitude in dB of the frequency response of the Hamming window
X (k) = {0, 8, 0, 0, 0, 0, 0, 0}
(a) 1
(b)
16
X(k)
x(n)
-1 0
0 4 8 12 16 20 24 28 0 2 8 16 24 30
n k
(c) 1
(d)
12
X(k)
x(n)
-1 0
0 4 8 12 16 20 24 28 0 2 8 16 24 30
n k
(e) 1
(f)
6
X(k)
x(n)
0
-1
0 4 8 12 16 20 24 28 0 2 8 16 24 30
n k
2π 2π
Figure 6.9a shows the DFT magnitude spectrum of x(n) = e j 64 n + e j 64 2n . In (a),
the two frequency components of the signal are clearly identified. In (b), there is only
one peak, due to the truncation of the signal, and, clearly, the spectral representation
is not a clear identification of the constituent frequency components of the signal.
This is due to the convolution of the spectra of the signal and the rectangular window.
2π 2π
Figure 6.10a shows the DFT magnitude spectrum of x(n) = e j 64 n + e j 64 4n . In this
case, the separation of the frequency components is more. In (a), the two frequency
components of the signal are clearly identified. In (b) also, there are two peaks
although not as distinct as in (a), due to the truncation of the signal.
2π 2π
Figure 6.11a shows the DFT magnitude spectrum of x(n) = e j 64 n + 0.1e j 64 14n .
In this case, the amplitude of one of the frequency components is large compared with
the other. In (a), the two frequency components of the signal are clearly identified.
6.2 Leakage Effect 173
(a) (b)
64 30
20
|X(k)|
|X(k)|
10
0 0
0 1 2 3 4 5 0 1 2 3 4 5 6 7 8 9 10
k k
2π 2π
Fig. 6.9 a The DFT magnitude spectrum of x(n) = e j 64 n + e j 64 2n ; b the DFT magnitude spectrum
of truncated x(n)
(a) (b) 15
64
10
|X(k)|
|X(k)|
5
0 0
0 1 2 3 4 5 0 1 2 3 4 5 6 7 8 9 10
k k
2π 2π
Fig. 6.10 a The DFT magnitude spectrum of x(n) = e j 64 n + e j 64 4n ; b the DFT magnitude spec-
trum of truncated x(n)
(a) (b)
64
15
|X(k)|
|X(k)|
0 0
01 8 14 01 8 14
k k
2π 2π
Fig. 6.11 a The DFT magnitude spectrum of x(n) = e j 64 n + 0.1e j 64 14n ; b the DFT magnitude
spectrum of truncated x(n)
In (b), due to the truncation of the signal, the clear identification of the second
component is not possible due to the large side lobes of the rectangular window.
2π 2π
Figure 6.12a shows the DFT magnitude spectrum of x(n) = e j 64 n + 0.1e j 64 14n .
In (a), the two frequency components of the signal are clearly identified. In (b),
despite the truncation of the signal, the identification of the second component is
possible due to the small side lobes of the Hann window.
174 6 Aliasing and Leakage
(a) 64
(b)
8
|X(k)|
|X(k)|
0
0
01 8 14 01 8 14
k k
2π 2π
Fig. 6.12 a The DFT magnitude spectrum of x(n) = e j 64 n + 0.1e j 64 14n ; b the DFT magnitude
spectrum of truncated x(n) using the Hann window
As the DFT provides only the uniform samples of a spectrum, it is possible that
features such as the peak of a spectrum are missed. As this is like viewing the spectrum
through a picket-fence, this effect is called the picket-fence effect. The period in one
domain is always fixed by the uniform sampling interval in the other. Therefore, the
data record should be long enough to provide a sufficiently small sampling interval
in the frequency domain. If necessary, zero padding can be employed in the time
domain to reduce the spectral sampling interval.
Figure 6.13a shows the DFT samples of the continuous spectrum of a signal. The
main lobe peak is missed. Figure 6.13b shows the DFT samples of the continuous
spectrum of the zero-padded signal to make its length double. This reduces the
sampling interval of the spectrum by one-half and the main lobe peak is located. In
general, sufficient record length should be ensured by zero padding or otherwise so
that all the important features of the spectrum are located.
(a) 60
(b) 60
|X(k)|
|X(k)|
40 40
20 20
0 0
0 1 2 3 4 5 0 1 2 3 4 5
k k
Fig. 6.13 a The DFT samples of the continuous spectrum of a signal; b the DFT samples of the
zero-padded signal
6.4 Summary 175
6.4 Summary
• The DFT is used to approximate all other versions of Fourier analysis. While the
DFT is finite and discrete in both the domains, signals may have infinite duration
and/or infinite bandwidth. Further, most of the naturally occurring signals are
continuous type. Therefore, signal analysis by the DFT is only approximate but
can be made adequate.
• The approximation of the signals to suit the DFT analysis usually requires sam-
pling, truncation, and quantization.
• The sampling theorem stipulates that a sinusoid with frequency f Hz requires
more than 2 f samples for its unambiguous representation in its sampled form.
• If the sampling theorem is not satisfied, then aliasing occurs. Aliasing is the imper-
sonation by a low-frequency discrete sinusoid of a higher-frequency continuous
sinusoid, due to a sampling interval not short enough.
• In order to avoid aliasing in the representation of a signal, the sampling interval
must be sufficiently short. Given a sampling interval, the signal has to be prefiltered
by an antialiasing filter so that the sampling theorem is satisfied. If aliasing is
unavoidable, then it has to be ensured, by selecting a sampling interval that is as
short as possible, that the error in the representation of the signal is negligible.
• The sampled version can be made sufficiently accurate, since signals generated
by physical devices are characterized by a drooping spectrum with increasing
frequency.
• As the duration of the signal may be very long, truncation is usually required.
• The DFT requires that all the frequency components of a signal complete an
integral number of cycles in the record length for its accurate representation. This
requirement may be violated due to truncation.
• Truncation reduces the resolution, which is the clear identification of the different
frequency components. Further, the energy of the frequency components is leaked
to neighboring frequencies indicating nonexisting frequency components in the
spectrum.
• Truncation is modeled as multiplying the signal by a rectangular window. This
window provides the best resolution of a truncated signal compared with other
windows but results in large leakage of energy. This is due to the discontinuity
created by this window at the borders, since a discontinuity makes the convergence
of the spectrum slow.
• The tapered windows eliminate or reduce the discontinuity by gradually reducing
the data towards the ends of the data record. This reduction in the discontinuity
reduces the leakage at the cost of reducing the spectral resolution. The reduc-
tion in leakage improves the ability to detect frequency components with small
magnitudes.
• Several tapered windows are available with different characteristics. The window
suitable for a specific application should be selected.
176 6 Aliasing and Leakage
• The truncated version can be made sufficiently accurate, since signals generated
by physical devices are characterized by a drooping amplitude with increasing
time.
• As the DFT provides only the samples of a spectrum, it is possible that features
such as the peak of a spectrum are missed. This effect is called the picket-fence
effect.
• The data record in the time domain should be long enough to provide a sufficiently
small sampling interval in the frequency domain. If necessary, zero padding can
be employed to reduce the spectral sampling interval.
Exercises
6.1 Given a periodic signal x(n) with period N = 4. Increase the value of the fre-
quency index from k = 0 to k = 8 and find the 4 samples for each k. Verify that the
equation
Ae j ( 4 (k+4l)n+φ) = Ae j ( 4 kn+φ) , n = 0, 1, 2, 3
2π 2π
* 6.1.1
x(n) = 2e j ( 4 kn+ 3 ) , n = 0, 1, 2, 3
2π π
6.1.2
x(n) = e j ( 4 kn− 4 ) , n = 0, 1, 2, 3
2π π
6.1.3
x(n) = −e j ( 4 kn− 3 ) , n = 0, 1, 2, 3
2π π
6.1.4
x(n) = −2e j ( 4 kn+ 6 ) , n = 0, 1, 2, 3
2π π
6.1.5
x(n) = 3e j ( 4 kn+ 8 ) , n = 0, 1, 2, 3
2π π
6.2 Given a periodic signal x(n) with period N = 8. Increase the value of the fre-
quency index from k = 0 to k = 12 and find the 8 samples for each k. Verify that the
equations
2π 2π N
x(n) = cos (k + l N )n + φ = cos kn + φ , k = 0, 1, . . . , − 1
N N 2
2π 2π N
x(n) = cos (k + l N )n + φ = cos(φ) cos kn , k =
N N 2
2π 2π
x(n) = cos (l N − k)n + φ = cos kn − φ ,
N N
6.4 Summary 177
N
k = 1, 2, . . . , − 1, n = 0, 1, 2, 3, 4, 5, 6, 7
2
hold, where l is an integer.
6.2.1
2π π
x(n) = cos kn −
8 6
* 6.2.2
2π π
x(n) = −2 cos kn +
8 6
6.2.3
2π π
x(n) = − cos kn −
8 4
6.2.4
2π π
x(n) = cos kn −
8 8
6.2.5
2π π
3 cos kn −
8 5
6.3 List the values of the rectangular window wr (n) with N = 8 and L = 5. Verify
these values by finding the IDFT of its frequency-domain version. Find the truncated
version, xt (n), of one cycle of x(n) by applying the window with L = 5. Find the
magnitude of the DFT, X t (k), of xt (n).
6.3.1
2π
x(n) = cos n , n = 0, 1, 2, 3, 4, 5, 6, 7
8
6.3.2
2π
x(n) = cos 2n , n = 0, 1, 2, 3, 4, 5, 6, 7
8
* 6.3.3
2π
x(n) = cos 3n , n = 0, 1, 2, 3, 4, 5, 6, 7
8
6.3.4
2π π
x(n) = cos n− , n = 0, 1, 2, 3, 4, 5, 6, 7
8 3
178 6 Aliasing and Leakage
6.3.5
2π π
x(n) = cos n+ , n = 0, 1, 2, 3, 4, 5, 6, 7
8 6
6.4 List the values of the Hann window whan (n) with N = 8 and L = 5. Verify
these values by finding the IDFT of its frequency-domain version. Find the truncated
version, xt (n), of one cycle of x(n) by applying the window with L = 5. Find the
magnitude of the DFT, X t (k), of xt (n).
6.4.1
2π
x(n) = cos n , n = 0, 1, 2, 3, 4, 5, 6, 7
8
6.4.2
2π
x(n) = cos 2n , n = 0, 1, 2, 3, 4, 5, 6, 7
8
6.4.3
2π
x(n) = cos 3n , n = 0, 1, 2, 3, 4, 5, 6, 7
8
* 6.4.4
2π π
x(n) = cos n− , n = 0, 1, 2, 3, 4, 5, 6, 7
8 3
6.4.5
2π π
x(n) = cos n+ , n = 0, 1, 2, 3, 4, 5, 6, 7
8 6
Chapter 7
Fourier Series
Signals and spectrums can be continuous or discrete and periodic or aperiodic. There
are four possibilities resulting in the four versions of the Fourier analysis, as shown
in the Tables 7.1 and 7.2. In both the time and frequency domains, the DFT (discrete
Fourier transform) version is discrete and periodic. In both the time and frequency
domains, the FT (Fourier transform) version is continuous and aperiodic. The FS
(Fourier series) version is continuous and periodic in the time domain and it is discrete
and aperiodic in the frequency domain. The DTFT (discrete-time Fourier transform)
version is continuous and periodic in the frequency domain and it is discrete and
aperiodic in the time domain. Note the duality between the DTFT and FS. Fourier
analysis is representation of an arbitrary waveform in terms of sinusoids. It enables
to determine the sinusoidal content of the waveforms. The differences between the
versions are that signals and their spectra being continuous or discrete and periodic
or aperiodic.
Each of the four versions of the Fourier analysis can be independently developed
using the orthogonal properties of the sinusoids. We have first derived the DFT version
for two major reasons. One is that it is the only version that can be implemented using
digital systems and all the other three versions are approximated, in practice, using the
DFT. Another reason is that it is the easiest to visualize the analysis and synthesis of
the waveforms. Therefore, we derive the three other versions of the Fourier analysis
starting from the DFT.
In this chapter, we derive the FS version of the Fourier analysis. In the Fourier
series representation, the time-domain waveform is continuous and periodic and
the corresponding spectrum in the frequency domain is discrete and aperiodic. A
continuous periodic waveform is represented as a sum of sinusoids whose frequencies
are integral multiples of that of the smallest, called the fundamental. The other
sinusoids are called the harmonics. The frequency of the fundamental component
is called the fundamental frequency. The multiplicative inverse of the period of the
periodic waveform being represented is the cyclic fundamental frequency. The cyclic
frequency multiplied by 2π is the frequency in radians. If the independent variable
© Springer Nature Singapore Pte Ltd. 2018 179
D. Sundararajan, Fourier Analysis—A Signal Processing Approach,
https://doi.org/10.1007/978-981-13-1693-7_7
180 7 Fourier Series
of the time-domain waveform is time, then the unit of the cyclic frequency, usually
denoted by f , is cycles per second (Hz). The unit of the radian frequency, usually
denoted by ω, is radians per second. However, it should be remembered that Fourier
analysis is equally applicable even if the independent variable is other than time. For
example, the periodicity of the rate of change of intensity of the pixels with respect
to distance is of interest in image processing.
The frequency increment of the spectrum of a periodic function is equal to its
fundamental frequency. If the number of samples in a period is increased in the
DFT representation of a signal, then, due to a longer range of the spectrum, the
number of frequency components is increased with the ability to represent a more
rapidly varying periodic waveform. When the sampling interval approaches zero, the
resulting waveform becomes continuous and periodic. The aperiodic nature of the
spectrum can be considered as a periodic spectrum becoming aperiodic in the limit
as the period becomes infinite.
{2f0 , 3f0 , . . . , ∞}
called the harmonic frequencies. A sinusoid with frequency kf0 is the kth harmonic of
the fundamental sinusoid with frequency f0 . The corresponding radian frequencies
are
{ω0 = 2πf0 , 2ω0 = 2π(2f0 ), 3ω0 = 2π(3f0 ), . . . , ∞}
7.1 Fourier Series 181
In Eq. (7.1), x(t) and the frequencies of the sinusoids are known. The Fourier analysis
problem is the determination of the amplitudes and phases of the sinusoids so that the
equation is satisfied in the least squares error sense. While, in theory, the frequency
range of the sinusoids is infinite, as no physical device can generate a harmonic of
infinite order, the number of harmonics used, in practice, is always finite.
Using trigonometric identities, Eq. (7.1) can be equivalently expressed, in terms
of cosine and sine waveforms, as
∞
2π
x(t) = Xc (0) + (Xc (k) cos(kω0 t) + Xs (k) sin(kω0 t)), ω0 = (7.2)
T
k=1
Using the Euler’s formula, Eq. (7.1) can also be equivalently expressed, in terms of
complex exponentials with a pure imaginary exponent, as
∞
2π
x(t) = Xfs (k)ejkω0 t , ω0 = (7.3)
T
k=−∞
FS can be derived using the orthogonality property of the sinusoids, similar to the
derivation of the DFT. In this section, we derive the FS as a limiting case of the DFT
with the sampling interval of the time-domain sequence tending to zero. We use the
center-zero format for convenience. Let the DFT of sequence x(n), N ≤ n ≤ N be
X (k), N ≤ k ≤ N . Then, the Fourier representation of x(n) is given as
1
N
j (2N2π+1) nk
x(n) = X (k)e , n = 0, ±1, ±2, . . . , ±N (7.4)
2N + 1
k=−N
where
N
x(m)e−j (2N +1) mk
2π
X (k) = (7.5)
m=−N
182 7 Fourier Series
T
= 2N + 1
Ts
The index of the time-domain samples has to be replaced by nTs s. The fundamental
frequency is
2π 2π
ω0 = =
T (2N + 1)Ts
where
T /2 T
1 1
Xfs (k) = x(t)e−jkω0 t dt = x(t)e−jkω0 t dt (7.10)
T −T /2 T 0
As x(t) is periodic with period T , the integral can be evaluated over any continuous
interval of duration T . Two commonly used limits are shown in Eq. (7.10). Equa-
tions (7.9) and (7.10) are, respectively, the exponential form of the FS synthesis and
analysis of x(t).
A periodic waveform
2π
x(t) = 0.2 + cos t
16
with period T = 16 s is shown in Fig. 7.1a. The cyclic frequency is f0 = 1/16 Hz and
its radian frequency is ω0 = 2π/16 rad/s. The FS for x(t) in exponential form, using
Euler’s formula, is
1 j 2π t 1 −j 2π t
x(t) = 0.2 + e 16 + e 16
2 2
and its spectrum is shown in Fig. 7.1b. With 3 time-domain samples, we can repre-
sent the DC component and the fundamental harmonic. With the same period, the
waveform, shown in Fig. 7.1c,
2π 2π
x(t) = 0.2 + cos t + 0.3 cos 3t ,
16 16
with a higher frequency content, requires a minimum of 7 samples. The FS for x(t)
in exponential form is
1 j 2π t 1 −j 2π t 0.3 j 2π 3t 0.3 −j 2π 3t
x(t) = 0.2 + e 16 + e 16 + e 16 + e 16
2 2 2 2
Its spectrum is shown in Fig. 7.1d. With more number of samples, the time-domain
waveform becomes more densely sampled and its spectrum becomes longer. With
the same period, the waveform, shown in Fig. 7.1e,
2π 2π 2π
x(t) = 0.2 + cos t + 0.3 cos 3t + 0.2 cos 5t ,
16 16 16
with a still higher frequency content, requires 11 samples. The FS for x(t) in expo-
nential form is
184 7 Fourier Series
(a) (b)
1
T=16 0.5
X fs (k)
x(t)
0.2
T s =16/3
0 4 8 12 -1 0 1
t, seconds k
(c) (d)
1 0.5
T=16
X fs (k)
x(t)
0 0.2
0.15
0
-1 T s =16/7
0 4 8 12 -3 -2 -1 0 1 2 3
t, seconds k
(e) (f)
0.5
1
X fs (k)
T=16
x(t)
0 0.2
0.15
0.1
0
-1 T s =16/11
0 4 8 12 -5 -3 -1 0 1 3 5
t, seconds k
Fig. 7.1 a A periodic waveform with the DC and the fundamental; b its FS spectrum; c a periodic
waveform with the DC, the fundamental and the 3rd harmonic; d its FS spectrum; e a periodic
waveform with the DC, the fundamental and the 3rd and 5th harmonics; f its FS spectrum
1 j 2π t 1 −j 2π t 0.3 j 2π 3t 0.3 −j 2π 3t
x(t) = 0.2 + e 16 + e 16 + e 16 + e 16
2 2 2 2
0.2 j 2π 5t 0.2 −j 2π 5t
+ e 16 + e 16
2 2
Its spectrum is shown in Fig. 7.1f. The time-domain waveform becomes more densely
sampled than those of (a) and (c) and its spectrum is longer than those of (b) and (d).
In the limit, the sampling interval tends to zero. The time-domain waveform becomes
continuous with the same period and the spectrum becomes aperiodic with the same
harmonic spacing.
7.1 Fourier Series 185
With the sinusoids represented in polar form, we get the compact trigonometric
form of the FS. Equation (7.9) can be rewritten as
∞
x(t) = Xfs (0) + (Xfs (k)ejkω0 t + Xfs (−k)e−jkω0 t )
k=1
All the terms, except the constant term Xfs (0), are complex conjugate pairs. The pair
with k = ±1 combines to form the fundamental sinusoid. The pair with k = ±2
combines to form the second harmonic and so on. Using Euler’s formula, we get
∞
x(t) = Xp (0) + Xp (k) cos(kω0 t + θ(k)), (7.11)
k=1
where
Comparing these two forms, the phase angles appear explicitly in the trigonometric
form whereas the complex coefficients of the complex form contain the phase angles
implicitly. While the complex form is the most suitable for analysis, the other form
is easier to visualize and physical devices generate the waveforms in that form.
With the sinusoids represented in rectangular form, we get another version of the
trigonometric form of the FS. Expressing the sinusoid in Eq. (7.11) in rectangular
form, we get
∞
x(t) = Xc (0) + (Xc (k) cos(kω0 t) + Xs (k) sin(kω0 t)), k = 1, 2, . . . , ∞ (7.12)
k=1
where Xc (0) = Xp (0), Xc (k) = Xp (k) cos(θ(k)), and Xs (k) = −Xp (k) sin(θ(k)).
Periodicity of the FS
The FS synthesized waveform is periodic with the same period as that of the funda-
mental, T = 2πω0
. Replacing t by t + mT in Eq. (7.11) with m being any positive or
negative integer, we get
∞
x(t + mT ) = Xp (0) + Xp (k) cos(kω0 (t + mT ) + θk )
k=1
∞
= Xp (0) + Xp (k) cos(kω0 t + 2kmπ + θk )
k=1
∞
= Xp (0) + Xp (k) cos(kω0 t + θk ) = x(t)
k=1
186 7 Fourier Series
If x(t) is defined only over a finite duration, then one period of the FS represents the
function. For a periodic x(t), the FS representation is valid for all t.
Existence of the FS
Dirichlet conditions specify the sufficient conditions for the existence of a FS rep-
resentation of a signal. As the coefficients are defined by an integral over a period,
the first condition is that the signal x(t) is absolutely integrable over one period. The
function to be integrated is the product of x(t) and the complex exponential with a
pure imaginary exponent. As the magnitude of the complex exponential is unity, the
T
condition is 0 |x(t)|dt < ∞. From the definition of the FS, we get
t1 +T t1 +T t1 +T
1 1 1
|Xfs (k)| ≤ |x(t)e−jkω0 t | dt = |x(t)||e−jkω0 t | dt = |x(t)| dt
T t1 T t1 T t1
since |e−jkω0 t | = 1.
The second condition is that the number of finite maxima and minima in one period
of the signal must be finite. The third condition is that the number of discontinuities
in one period of the signal must be finite. All signals generated by physical devices
satisfy these conditions.
Example 7.1 Find the three forms of the FS for the signal
2π π 1 2π π
x(t) = 1 − cos t− + sin 2 t +
8 3 2 8 6
1 2π 1 2π
− √ cos 3 t + √ sin 3 t
3 2 8 3 2 8
Solution
As x(t) can be rewritten in the form of the definitions easily, no evaluation of integral
is required to find its FS. The fundamental frequency of the waveform is ω0 = 2π 8
,
as the dc component is periodic with any period.
Compact Trigonometric Form
All the terms of x(t) are rewritten using cosine waveform with positive amplitude
for each frequency.
2π 2π 1 2π π 1 2π 3π
x(t) = 1 + cos t+ + cos 2 t − + cos 3 t −
8 3 2 8 3 3 8 4
Comparing this expression with the definition, Eq. (7.11), we get the compact
trigonometric form of the FS coefficients as
7.1 Fourier Series 187
2π 1 π
Xp (0) = 1, Xp (1) = 1, θ(1) = , Xp (2) = , θ(2) = − ,
3 2 3
1 3π
Xp (3) = , θ(3) = −
3 4
Trigonometric Form
√ √
1 2π 3 2π 1 2π 3 2π
x(t) = 1 − cos t − sin t + cos 2 t + sin 2 t
2 8 2 8 4 8 4 8
1 2π 1 2π
− √ cos 3 t + √ sin 3 t
3 2 8 3 2 8
Comparing this expression with the definition, Eq. (7.12), we get the trigonometric
form of the FS coefficients as
√
1 3 1
Xc (0) = 1, Xc (1) = − , Xs (1) = − , Xc (2) = ,
2 2 4
√
3 1 1
Xs (2) = , Xc (3) = − √ , Xs (3) = √
4 3 2 3 2
Exponential Form
1 2π 2π 1
x(t) = 1 + ej( 8 t+ 3 ) + e−j( 8 t+ 3 )
2π 2π
2 2
1 j(2 2π t− π ) 1 −j(2 2π t− π ) 1 j(3 2π t− 3π ) 1 −j(3 2π t− 3π )
+ e 8 3 + e 8 3 + e 8 4 + e 8 4
4 4 6 6
Comparing this expression with the definition, Eq. (7.9), we get the exponential form
of the FS coefficients as
2π 2π
Xfs (0) = 1, Xfs (1) = 0.5∠ , Xfs (−1) = 0.5∠− ,
3 3
π π
Xfs (2) = 0.25∠− , Xfs (−2) = 0.25∠ ,
3 3
1 3π 1 3π
Xfs (3) = ∠− , Xfs (−3) = ∠
6 4 6 4
frequencies divided by the least common multiple of the denominators, after cancel-
ing any common factors of the numerators and denominators of each of them. Note
that a constant signal (DC) is periodic with any period.
Solution
After canceling common factors of the frequencies
√ √ √
3 4 3 6 3
, , ,
7 6 3
we get √ √ √
3 2 3 2 3
, , ,
7 3 1
Example 7.3 Find the FS for the periodic impulse train with period T s defined as
∞
x(t) = δ(t − nT )
n=−∞
Solution
The impulse train is shown in Fig. 7.3a. Each impulse is of continuous type with
strength 1, indicated by an upward pointing arrow. As the continuous unit-impulse
signal δ(t), located at t = 0, is defined, in terms of an integral
∞
x(t)δ(t) dt = x(0)
−∞
7.1 Fourier Series 189
(a) 3 (b)
1
x(t)
x(t)
0 0
-1
-3
0 10 20 30 40 50 60 70 0 10 20 30 40 50 60 70
t, seconds t, seconds
(c) 1
(d) 1
x(t)
x(t)
0 0
-1 -1
0 10 20 30 40 50 60 70 0 10 20
t, seconds t, seconds
√
√
Fig. 7.2 a One cycle of the waveform x(t) with period 14 3π s; b sinusoid cos 73 t with 3
√
√
cycles in the period; c sinusoid cos 4 6 3 t with 14 cycles in the period; d sinusoid cos 6 3 3 t
with 42 cycles in the period (only a part of it is shown)
The spectrum, shown in Fig. 7.3b, is also a periodic impulse train with period ω0 = 2π
T
and amplitude T1 . Each impulse is of discrete type.
The FS coefficients, in compact trigonometric form, are
1 2
Xp (0) = Xfs (0) = , Xp (k) = 2|Xfs (k)| = , θ(k) = 0, . . . , k = 1, 2, 3, . . .
T T
190 7 Fourier Series
(a) (b)
1 1/T
X fs (k)
x(t)
0 0
-2T -T 0 T 2T -2 0 - 0 0 0
2 0
t
The FS is given by
1 2π
x(t) = (1 + 2(cos(ω0 t) + cos(2ω0 t) + cos(3ω0 t) + · · · )), ω0 = (7.13)
T T
As the impulse train is composed of cosine components only, the impulse is an even
signal.
1
x(t) ≈ (2 (1 + cos(t) + cos(2t) + cos(3t) + · · · + cos(Nt)) − 1)
2π
1 sin(0.5(2N + 1)t)
=
2π sin(0.5t)
Figure 7.4 shows the reconstructed impulse with (a) N = 8; (b) N = 16; (c) N = 32;
(d) N = 64; (e) N = 128; (f) N = 256. The waveforms are composed of a large
positive hump at the center and damped oscillations on either side. The total area of
the oscillations is 1 for any N . The area of the oscillations is negative. Therefore, the
area of the large hump must have an area greater than 1 by this amount so that the
net area becomes 1. As the impulse encloses an area of 1 at t = 0, the reconstructed
waveforms with a finite N are not ideal impulses. They are approximations of the
impulse. In the limit N → ∞, the large hump and the oscillations coincide at t = 0
and the reconstructed waveform attains its ideal form. Therefore, for finite values
of N , however large, the reconstructed waveform is a deviation from its ideal form.
In reconstructing waveforms with discontinuities, a suitable value for N has to be
chosen so that the deviation is acceptable.
7.1 Fourier Series 191
(a) (b)
2.7056 5.2521
N =8 N = 16
x(t)
x(t)
0 0
- 0 - 0
(c) t (d) t
10.3451 20.5310
N = 32 N = 64
x(t)
x(t)
0 0
- 0 - 0
(e) t (f) t
40.9028 81.6465
N = 128 N = 256
x(t)
x(t)
0 0
- 0 - 0
t t
Example 7.4 Find the FS for a square wave defined over one period as
1 for |t| < π2
x(t) =
0 for π2 < |t| < π
Solution
The square wave is shown in Fig. 7.6. The period of the waveform is 2π and the
fundamental frequency ω0 is one. The waveform is even-symmetric and, therefore,
the coefficients of all the sine components are zero. Further, subtracting the DC bias,
the first-half and second-half of x(t) are antisymmetric. This is called the odd half-
192 7 Fourier Series
wave symmetry. This implies that all the even-indexed, except the DC, components
are absent. Therefore, the waveform is composed of odd-indexed cosine waves and
a DC component.
π
2 2 1
Xc (0) = dt =
2π 0 2
π 2
4 2 sin π2 k for k odd
Xc (k) = cos(k t)dt = kπ
2π 0 0 for k even and k = 0
The FS magnitude spectrum and the phase spectrum of the signal in exponential
form are shown, respectively, in Fig. 7.5a, b.
(a) 0.5
(b)
(X fs (k))
0.3183
|X fs (k)|
0.1061
0 0
-3 -2 -1 0 1 2 3 -3 -2 -1 0 1 2 3
Fig. 7.5 a The FS magnitude spectrum and b the phase spectrum of the square wave in exponential
form
7.1 Fourier Series 193
x(t)
0.5 0.5
0 0
-0.1366 -0.1002
- -0.5 0 0.5 - 0
t t
(c) (d)
1.0921 1.0901
1 1
x(t)
x(t)
0.5 0.5
0 0
-0.0921 -0.0901
- 0 - 0
t t
Fig. 7.6 The FS reconstructed square wave. a Using up to the first harmonic; b using up to the
third harmonic; c using up to the seventh harmonic; d using up to the fifteenth harmonic
The reconstructed square waveforms using up to the first, third, seventh, and fif-
teenth harmonics are shown in Fig. 7.6a–d, respectively. The magnitude of the FS
coefficients decreases as the order of the harmonics increases, except for an impulse.
It is expected since the definition of the FS coefficients is an integral and the inte-
grand includes the complex exponential with k, the order of the harmonic, in its
exponent. Integrating a signal makes it smoother. For the square waveform, the coef-
ficients decrease at the rate of 1/k, where k is the order of the harmonic. The square
waveform is not differentiable, as it has discontinuities. The convolution output of
a square wave with itself is a triangular wave, whose first derivative has discon-
tinuities. As convolution becomes multiplication in the frequency domain, the FS
coefficients of the triangular waveform decrease at the rate of 1/k 2 , where k is the
order of the harmonic. Therefore, if the nth derivative of a waveform is the first one
having a discontinuity then its FS coefficients decrease at the rate of 1/k n+1 . The FS
representation converges uniformly at all points except at discontinuities.
The FS reconstructed waveform converges to the average of the two values of the
signal at the discontinuity. Let a and b be the values at the discontinuity and c is that
of the reconstructed waveform. As the reconstruction is with respect to least squares
error criterion,
194 7 Fourier Series
(c − a)2 + (c − b)2
must be minimum. Differentiating the expression with respect to c and equating the
resulting expression to zero, we get
c−a+c−b=0
Properties of signals and their transforms are useful in reducing the complexity of
signal analysis. For example, if the signal is even-symmetric then the determination of
its cosine components alone is adequate and the limits of the integration or summation
operations also get reduced. Further, with a knowledge of corresponding operations
in the time domain and frequency domain, they can be implemented in the appropriate
domain efficiently. For example, the implementation of the convolution operation of
long and arbitrary signals is more efficient in the frequency domain.
7.2.1 Linearity
if x(t) ↔ Xfs (k) and y(t) ↔ Yfs (k) then ax(t) + by(t) ↔ aXfs (k) + bYfs (k),
7.2 Properties of the Fourier Series 195
where a and b are arbitrary constants. It is the linearity property of the Fourier analysis
that makes it suitable in the analysis of linear systems. For example, the FS coef-
ficients for cos(t) and sin(t) are Xfs (±1) = 21 and Xfs (±1) = ∓ 2j , respectively. The
FS coefficients for 2 cos(t) − 2j sin(t) = 2e−jt are Xfs (±1) = 1 + (−j)(∓j). That is,
the only nonzero FS coefficient is Xfs (−1) = 2.
7.2.2 Symmetry
T
2 2
Xc (0) = x(t) dt,
T 0
T
4 2
Xc (k) = x(t) cos(kω0 t) dt, k = 1, 2, . . . , ∞
T 0
For example, the FS coefficients of the impulse train and the square waveform in the
earlier examples are even-symmetric.
If the signal is odd-symmetric, the coefficients corresponding to the sine compo-
nent only are nonzero. The spectrum is imaginary and odd.
T
4 2
Xs (k) = x(t) sin(kω0 t) dt, k = 1, 2, . . . , ∞
T 0
The square wave, in Example 7.4, pushed down by 0.5 along the vertical axis (so
that there is no DC bias) and shifted by π/2 s to the right becomes odd-symmetric
and its FS is
2 1 1
sin(t) + sin(3t) + sin(5t) + · · ·
π 3 5
Any signal x(t) can be decomposed into its even and odd components, xe (t) and
xo (t). The real part of the FS coefficients, Re(Xfs (k)), of a real-valued signal x(t) are
the FS coefficients of its even component xe (t) and j Im(Xfs (k)) are those of its odd
component xo (t).
Half-Wave Symmetry
This property is defined for periodic signals. If the first- and second-halves of a
waveform x(t), with period T , are the same, then it is said to have even half-wave
symmetry. That is x(t ± T2 ) = x(t). Obviously, it completes two cycles of a pattern
in the interval T and consists of even-indexed frequency components only. The FS
coefficients can be expressed as
T
1 2 T
Xfs (k) = x(t) + (−1) x t +
k
e−jkω0 t dt (7.15)
T 0 2
The full-wave rectified sine wave, presented later, is an example of this type of
waveform.
If the first- and second-halves of a waveform x(t), with period T , are the negatives
of each other, then it is said to have odd half-wave symmetry. That is −x(t ± T2 ) =
7.2 Properties of the Fourier Series 197
x(t). The even-indexed FS coefficients are zero. The odd-indexed FS coefficients are
given by
T
2 2
Xfs (k) = x(t)e−jkω0 t dt, k = 1, 3, 5, . . .
T 0
The square wave in Example 7.4, with the DC bias subtracted, is an example of this
type of waveform.
Any periodic signal x(t), with period T , can be decomposed into its even and
odd half-wave symmetric components xeh (t) and xoh (t), respectively. That is x(t) =
xeh (t) + xoh (t), where
1 T 1 T
xeh (t) = x(t) + x t ± and xoh (t) = x(t) − x t ±
2 2 2 2
This decomposition is the basis for the fast implementation of the Fourier analysis
in practical applications. A waveform composed of N frequency components is
decomposed into two waveforms, each of which is composed of N /2 frequency
components. This process is recursively continued resulting in fast algorithms.
Time shifting is an often used operation in signal analysis. The variable t in x(t) is
replaced by (t − t0 ). The origin of the signal is shifted by t0 . Shifting a signal does
not change its magnitude profile. Consider a typical harmonic component
Aej(kω0 t+θ)
Shifting it by t0 results in
The phase has been changed to (θ − kω0 t0 ). The change in phase is proportional
to the harmonic order k. Such a change of the phase of the harmonic components
of a waveform x(t) shifts it by t0 . Therefore, if x(t) ↔ Xfs (k) with the fundamental
frequency ω0 = 2π
T
, then
x(t ± t0 ) ↔ e±jkω0 t0 Xfs (k)
For example, the FS coefficients for cos(t) are Xfs (1) = 21 and Xfs (−1) = 21 . Let
us find the FS coefficients for cos(3t) cos(t). Since cos(3t) = 21 (ej3t + e−j3t ), the FS
coefficients for cos(3t) cos(t) is the sum of the FS coefficients for cos(t) shifted to
the right and left by 3, in addition to the scale factor 21 . That is,
1 1 1 1
Xfs (−4) = , Xfs (−2) = , Xfs (2) = , Xfs (4) =
4 4 4 4
1
(cos(2t) + cos(4t)) = cos(3t) cos(t)
2
As pointed in Chap. 3, the convolution of complex exponentials with the same fre-
quency is a complex exponential of the same frequency. However, the convolution
of complex exponentials with different harmonic frequencies is zero. Therefore, the
periodic convolution of x(t) and h(t), with a common period T , is given by
∞
y(t) = TXfs (k)Hfs (k)ejkω0 t ,
k=−∞
7.2 Properties of the Fourier Series 199
x(t) 3.1416
0
-3 -2 -1 0 1 2 3
t
Fig. 7.7 The reconstructed triangular wave, which is the convolution of the square wave with itself
where Xfs (k) and Hfs (k) are, respectively, the FS coefficients for x(t) and h(t). That
is,
T ∞
x(τ )h(t − τ )d τ = TXfs (k)Hfs (k)ejkω0 t ↔ TXfs (k)Hfs (k)
0 k=−∞
Consider the convolution of the square wave in Example 7.4 with itself. Its FS
representation is
1 2 1 1
x(t) = + cos(t) − cos(3t) + cos(5t) − · · ·
2 π 3 5
The complex FS coefficients of the square wave are squared pointwise, multiplied
by the period 2π and the Eulers’ formula is applied. The convolution output is given
by
1 2 1 1
y(t) = 2π + 2 cos(t) + cos(3t) + cos(5t) + · · ·
4 π 9 25
Given that z(t) = x(t)y(t) with period T , the transform of z(t), Zfs (k), is to be
expressed in terms of those of the component functions, Xfs (k) and Yfs (k). Let the
FS representations of x(t) and y(t) be
200 7 Fourier Series
x(t) = Xfs (1)ejω0 t + Xfs (2)ej2ω0 t and y(t) = Yfs (1)ejω0 t + Yfs (2)ej2ω0 t
with each one having just two frequency components. The product of the two func-
tions is given by
z(t) = x(t)y(t)
= Xfs (1)Yfs (1)ejω0 t + (Xfs (1)Yfs (2) + Xfs (2)Yfs (1))ej3ω0 t + Xfs (2)Yfs (2)ej2ω0 t
∞
∞
z(t) = x(t)y(t) = Xfs (p)Yfs (k − p) ejkω0 t
k=−∞ p=−∞
T ∞
1
x(t)y(t) ↔ x(t)y(t)e−jkω0 t dt = Xfs (p)Yfs (k − p)
T 0 p=−∞
As the spectrum is symmetric, only part of the one side of the coefficients are given.
The odd-indexed coefficients are quite accurate. The even-indexed (except the DC
component) are close to zero, but not zero as expected. Convolving a set of 23
coefficients with itself yields
The value of the DC component becomes still closer to the exact value and the values
of the other even-indexed coefficients become more closer to zero. Remember that,
the rate of convergence of the coefficients of the square wave is low due to its
discontinuities.
It is often required to change the time scale of the function x(t) with period T by
replacing t by at (a = 0). The result of time scaling is that the spectrum remains
the same with the fundamental frequency changed to aω0 , where ω0 = 2π/T . For
example, let a = 2. The square wave in Example 7.4, with period 2π, becomes
periodic with period π. Therefore, the fundamental frequency becomes 2π/π = 2.
The waveform gets compressed. The compression of a function in the time domain
results in the expansion of its spectrum. The FS series representation of the square
wave becomes
1 2 1 1
x(t) = + cos(2t) − cos(6t) + cos(10t) − · · ·
2 π 3 5
With a > 1, the signal is compressed and the spectrum is expanded. With 0 <
a < 1, the signal is expanded and the spectrum is compressed. With
with the fundamental frequency aω0 and a > 0. For negative values of a, the spectrum
is also frequency-reversed with the fundamental frequency |a|ω0 .
Therefore,
d n x(t)
↔ ( jkω0 )n Xfs (k)
dt n
Note that the DC component becomes zero in the differentiation process. Similarly,
t
1
x(τ )d τ ↔ Xfs (k)
−∞ jkω0
provided the dc component of x(t) is zero (Xfs (0) = 0). Successive integration of
x(t) can be carried out.
One period of the square wave, with ω0 = 1, in Example 7.4 can be expressed, in
terms of time-shifted unit-step signals, as
π
π
u t+ −u t− , −π < t < π
2 2
The derivative, with respect to t, of this signal in a period is composed of impulses
π
π
δ t+ −δ t−
2 2
The FS coefficients are given by
1 π 1
π
jk π2
e − e−jk 2 = j2 sin k
T T 2
Dividing by jk and with T = 2π, we get the FS coefficients of the square wave as
1
π
Xfs (k) = sin k
kπ 2
A detailed derivation is as follows. Using the time-shifting property and the FS
coefficients of the impulse δ(t), we get
7.2 Properties of the Fourier Series 203
π
π
δ t+ −δ t−
2 2
1 1 1̌ 1 1
←→ . . . , , − , , , − , . . .
T T T T T
1 1 1̌ 1 1
− ...,− , , ,− , ,...
T T T T T
1
(· · · − e−j5t + e−j3t − e−jt + ejt − ej3t + ej5t + · · · )
π
Integrating this function, we get
1 1 1 1 1
· · · + e−j5t − e−j3t + e−jt + ejt − ej3t + ej5t + · · ·
π 5 3 3 5
1 1 1 1 1 1
(· · · + e−j5t − e−j3t + e−jt + + ejt − ej3t + ej5t + · · · )
π 5 3 2 3 5
As Fourier analysis belongs to the class of orthogonal transforms, it has the power
preserving property. That is, the average signal power remains the same in its trans-
formed representation. The signal is expressed as a sum of complex exponentials of
harmonic frequencies in its FS representation. The magnitude of each complex expo-
nential is 1. Therefore, the total power in a period of period T is T and the average
power is T /T = 1. For a specific harmonic component with coefficient Xfs (k), the
average power is |Xfs (k)|2 . The total power is the sum of those of all the harmonics.
That is, the total average power of a signal is
T ∞
1
P= |x(t)|2 dt = |Xfs (k)|2
T 0 k=−∞
Example 7.5 Find the power of the square wave of Example 7.4 in both the time and
frequency domains. Find the power upto the fifth harmonic.
204 7 Fourier Series
Solution
From the time-domain representation, we get
T π
1 1 2 1
P= |x(t)| dt =
2
dt =
T 0 π 0 2
The sum of the power of the components of the signal up to the fifth harmonic is
1 2 2 2
+ + 2+ = 0.4833
4 π2 9π 25π 2
As stated earlier, Fourier analysis approximates a signal adequately with a finite
number of frequency components with respect to the power or amplitude of the
signal.
Apart from signal compression applications, the two major applications of Fourier
analysis are: (i) the amplitude and/or power spectrum of a signal reveals impor-
tant characteristics of the signal pertinent to its use in applications and (ii) efficient
implementation of system input–output models such as convolution and differential
equation. In Fourier analysis, a signal can be adequately approximated, for practical
purposes, by a sum of a finite number of sinusoids. Large number of practical systems
can be modeled adequately as linear systems. Then, the response of a system to an
arbitrary input signal can be obtained by a linear combination of the responses to
the constituent sinusoids. The result is that the response of systems can be obtained
faster than other methods in most cases.
The FS representation is important in linear systems analysis due to its approxi-
mation of arbitrary signals over a given interval by a sum of sinusoids. The linearity
property of such systems permits the superposition of the responses to individual
sinusoids. This procedure makes the simplicity of sinusoidal steady-state analysis
applicable to arbitrary input signals.
Some of the important Fourier series applications include network analysis and
synthesis, vibration analysis, electrical power system waveform analysis, power con-
version circuit analysis, acoustics, medical signal analysis, communication circuit
analysis, and control system analysis. For example, the electrocardiogram shows the
cardiac cycle of a patient. It is a periodic signal with frequency about 4/3 Hz. The
7.3 Applications of the Fourier Series 205
Invariably, all electronic devices contain power conversion circuits to convert the
alternating current input supply voltage to DC voltage. This requires rectifiers fol-
lowed by lowpass filters. As the input voltage is periodic, FS is the appropriate tool
in the analysis of the rectified power supply. Let us find the FS representation of the
full-wave rectified waveform given by
x(t) = | sin(t)|
∞
2 4 1
x(t) = + cos(2kt)
π π 1 − 4k 2
k=1
2 4 4 4
= − cos(2t) − cos(4t) − cos(6t) − · · ·
π 3π 15π 35π
206 7 Fourier Series
(a) (b)
1 1.0610
DC
0.6366
x(t)
x(t)
0 0
0 0
t t
(c) (d)
1 1
x(t)
x(t)
0 0
0 0
(e) t (f) t
0.0849 0.0364
x(t)
x(t)
0 0
-0.0849 -0.0364
0 0
t t
Fig. 7.8 a Full-wave rectified sine wave; b its reconstruction with DC and 2nd harmonic; c and
d its reconstruction with up to 4th and 6th harmonics, respectively; e the 4th harmonic; f the 6th
harmonic
Figure 7.8b shows its DC component and its reconstruction with the DC and the
2nd harmonic. Figure 7.8c shows its reconstruction with the DC and the 2nd and 4th
harmonics. Figure 7.8d shows its reconstruction with the DC and the 2nd, 4th, and
6th harmonics. As expected, the reconstructed waveform becomes more closer to the
original with the addition of more harmonic components.
While signal reconstruction is an important aspect of Fourier analysis, the magni-
tude of the harmonics is another important aspect. Figure 7.8e, f show, respectively,
the fourth and sixth harmonics of the waveform in (a). The harmonics make 4 and 6
cycles in a period. In most applications, the harmonics are considered as unwanted
components of the waveform. The harmonic magnitudes have to be smaller than a
given specification. That requires some sort of filtering. In order to design a suitable
filter, Fourier analysis is required, in the first place, to estimate the magnitudes of the
harmonics.
7.3 Applications of the Fourier Series 207
When the excitation to a linear system is a complex exponential, the form of the
response at any part of the system is also the same exponential with changes only
in magnitude and phase. The frequency remains unchanged. This property, along
with the linearity property, makes the steady-state output of a stable system to be
determined by the superposition sum of the responses due to all the constituent
exponentials of an arbitrary input signal. A continuous periodic input signal can be
decomposed into a sum of exponentials with harmonic frequencies by the FS.
The steady-state output of a LTI system to an input e jk0 ω0 t is the same function
multiplied by the complex scale factor, H ( jk0 ω0 ), called the frequency response.
Therefore, the output of the system is H ( jk0 ω0 )e jk0 ω0 t . The function H ( jkω0 ) is
obtained by sampling the continuous frequency response H ( jω) of the system at the
discrete frequencies ω = kω0 .
For an arbitrary continuous periodic input signal, as
∞
x(t) = Xfs (k)e jkω0 t
,
k=−∞
k=−∞
jωLIe jωt
Iejωt
jωC
Therefore, the model for a capacitor, in the frequency domain, is 1/(jωC). The
model for a resistor, in the frequency domain, is R itself. The value is unaffected by
the frequency.
The opposition to the flow of current through an inductor or capacitor is called the
reactance. The sum of resistance and reactance is called the impedance. For example,
the impedance of a series connected resistor R and inductor L is R + jωL. Similarly,
the impedance of a series connected resistor R and capacitor C is R + (1/(jωC)). The
reactance due to an inductor is zero at ω = 0 and increases with increasing frequency.
The reactance due to a capacitor is infinite at ω = 0 and decreases with increasing
frequency. Therefore, for a given current, the voltage across an inductor increases
with increasing frequency. The voltage across a capacitor decreases with increasing
frequency. A resistor is required to limit the current at low and high frequencies.
These characteristics enable to build filter circuits with resistors, capacitors, and
inductors.
Let the input x(t) = | sin(t)| be applied to the lowpass filter circuit, shown in
Fig. 7.9. It is a series resistor–capacitor network, with the resistor 10 and capacitor
1/2 F. The task is to find an expression for the output voltage across the capacitor,
y(t).
The FS for the full-wave rectified sine wave is
∞
2 4 1
x(t) = + cos(2kt)
π π 1 − 4k 2
k=1
2 4 4 4
= − cos(2t) − cos(4t) − cos(6t) + · · ·
π 3π 15π 35π
The voltage across the capacitor, by voltage division, is
1/(jωC) 1
y(t) = x(t) = x(t)
R + 1/(jωC) 1 + jωRC
x(t) ↑ ∼ 1 ↑ y(t)
2 F
i(t) = C dy(t)
dt
7.3 Applications of the Fourier Series 209
When the input is a sinusoid or a complex exponential, the Ohm’s law, for circuits
with resistances, is extended to circuits with energy storage elements inductor and
capacitor with the impedance replacing the resistance. For DC, with the fundamental
frequency ω0 = 1 and k = 0,
2
y(t) =
π
since the capacitor is an open circuit to DC. For the 2nd harmonic, with the funda-
mental frequency ω0 = 1 and k = 2,
4 1
y(t) = − cos(2t)
3π 1 + j2RC
The magnitude of the 2nd harmonic has been reduced by a factor of 0.0995. Therefore,
the output waveform will have ripples of a smaller magnitude and is more closer
to the required output, which is DC. The factor in the denominator attenuates the
frequency components other than DC in proportion to the frequency. As the frequency
approaches infinity, the input components are almost blocked.
The total response of the circuit is the sum of the responses to all the harmonic
components of the input. The RC circuit is called a lowpass filter as it passes more
readily the low-frequency components of the input compared with those of the high-
frequency components. In practice, the FS, approximated by the DFT, can only have
a finite number of terms. Therefore, the number of terms has to be fixed depending
on the accuracy required.
For the resistor–inductor series circuit shown in Fig. 7.10, the input–output rela-
tionship is given by
jωL
y(t) = x(t)
1 + jωRL
y(t) = 0
since the inductor is a short circuit to DC. For the 2nd harmonic, with the fundamental
frequency ω0 = 1 and k = 2,
4 j2L
y(t) = − cos(2t)
3π 1 + j2RL
The magnitude of the 2nd harmonic has been reduced by a factor of 0.3322. As the
frequency approaches infinity, the input components are more readily passed. The
total response of the circuit is the sum of the responses to all the harmonic components
of the input. The RL circuit is called a highpass filter as it passes more readily the
high-frequency components of the input compared with those of the low-frequency
components.
The frequency-domain analysis is similar in other applications. For example, in
mechanical engineering, resistor, inductor, and capacitor correspond, respectively,
to friction, spring, and mass.
In practice, the amplitude profiles of practical waveforms are arbitrary and, invariably,
the other versions of the Fourier analysis have to be approximated by the DFT and
the IDFT. The integral in Eq. (7.10) is numerically evaluated by using the DFT. The
DFT uses the samples over one period of the periodic signal x(t) with period T . The
sampling interval is Ts = NT and the number of samples is N . The N samples of x(t)
over one period are
In numerical approximation, sampling interval has to be a finite value, but not zero, to
keep the number of samples finite. Let us ignore the limiting process for sufficiently
small values of Ts , which will result in aliasing error. Then, the FS analysis equation
is approximated by
N −1
1
x(nTs )e−j N nk , k = 0, 1, . . . , N − 1
2π
Xfs (k) = (7.16)
N n=0
N −1
j 2π
x(n) = Xfs (k)e N nk , n = 0, 1, . . . , N − 1.
k=0
The numerical approximations of the FS analysis and synthesis equations are the
same as the DFT and IDFT equations, with a scale factor. Remember that Xfs (k) is
aperiodic and the DFT spectrum is periodic. If x(t) is band-limited and adequate
number of samples is taken over a period, the assumed periodicity of the DFT is not
a problem. If it is not the case, aliasing of the spectrum will arise. Then, it has to be
ensured that the quality of the spectrum is adequate by taking sufficient number of
samples.
For N even, comparing the coefficients of the DFT with that in Eq. (7.10), we get,
for real signals,
X (k) N N X N2
Xfs (k) = , k = 0, 1, . . . , − 1 and Re Xfs = (7.17)
N 2 2 2N
1 1 1 1
3 + √ ,2 − √ ,1 + √ ,2 − √ = {3.7071, 1.2929, 1.7071, 1.2929}
2 2 2 2
212 7 Fourier Series
The period of the spectrum is determined by the sampling interval in the time domain.
The sampling process can be modeled as multiplying the continuous function by an
impulse train. Multiplication in the time domain corresponds to convolution of the
spectra of the impulse train, which is also an impulse train, and the continuous
function. The convolution of the FS spectrum with an impulse is relocating the
aperiodic spectrum at the location of the impulse. The combined spectrum of these
shifted spectra is the spectrum of the sampled function. To recover the continuous
signal back from the spectrum of the sampled signal to a good approximation requires
that the periodic repetition of the spectrum does not overlap within each period. In
practice, negligible overlapping is acceptable.
Consider the waveform x(t)
2π 2π
x(t) = 0.2 + cos t + 0.3 cos 3t
16 16
1 j 2π t 1 −j 2π t 0.3 j 2π 0.3 −j 2π 3t
= 0.2 + e 16 + e 16 + e 16 3t + e 16
2 2 2 2
ˇ
Xfs (k), k = −3, −2, −1, 0, 1, 2, 3 = {0.15, 0.00, 0.50, 0.20,0.50, 0.00, 0.15}
If we sum the shifted copies of the spectral values placed at a distance of 4 samples,
ˇ 0.65, 0.00, 0.65}.
we get a corrupted periodic spectrum {0.20,
ˇ
{0.20,0.65, 0.00, 0.65}
Equation (7.18)
∞
X (k) = N Xfs (k − mN ), k = 0, 1, . . . , N − 1 (7.18)
m=−∞
7.5 Summary
• FS is one of the four versions of Fourier analysis that provides the representation
of a continuous periodic time-domain waveform by a discrete aperiodic spectrum
in the frequency domain.
• FS represents a continuous periodic waveform as a linear combination of sinusoidal
or, equivalently, complex exponential basis functions of harmonically related fre-
quencies.
• Harmonics are any of the frequency components whose frequencies are integral
multiples of a fundamental. The frequency of the fundamental is the same as that
of the periodic waveform being analyzed.
• The FS is the limiting case of the DFT as the sampling interval of the time-domain
sequence tends to zero with the period fixed.
• While physical devices generate real sinusoidal waveforms, it is found that the
analysis is mostly carried out using complex exponentials due to its compact form
and ease of manipulation.
• While an infinite number of frequency components are required to represent an
arbitrary waveform exactly, it is found that, in practice, a finite number of frequency
components provides an adequate representation.
• The orthogonality property of the basis signals makes it easy to determine the FS
coefficients.
• The representation of a signal in terms of its spectrum is just as complete and
specific as its time-domain representation in every respect.
• The independent variable of the waveform may be other than time, such as distance.
• The conditions for the existence of a Fourier representation of a waveform are met
by signals generated by physical devices.
• The amplitude versus frequency plot of the harmonics is called the spectrum. As
the spectrum is usually complex, it is represented by two plots, either the real and
imaginary parts or the magnitude and phase. While the time-domain waveform is
continuous and periodic, its FS spectrum is aperiodic and discrete.
• The more smoother the waveform, the faster is the convergence of its spectrum.
• A signal can be reconstructed using its spectral components.
• The exponential and trigonometric forms of Fourier analysis are related by the
Euler’s formula.
• The least squares error is the criterion for the representation of a signal by the
Fourier analysis. With respect to this criterion, there is no better approximation
than that provided by the Fourier analysis.
• The properties of Fourier analysis help to relate the effects of characteristics of
signals in one domain into the other.
• LTI system analysis is simpler with the Fourier representation of signals and sys-
tems.
• The Fourier spectrum can be adequately approximated by the DFT in practical
applications.
7.5 Summary 215
* 7.2.2
3 2
x(t) = 1 − 2 sin t + sin t
6 9
7.2.3
5 4
x(t) = 4 + 3 cos t + 3 cos t
7 6
7.3
* 7.3.1 Find the FS for a periodic pulse train defined over one period as
1 for |t| < a
x(t) =
0 for a < |t| < T
2
7.3.3
Find the FS for a saw-tooth signal defined over one period as
7.4
* 7.4.1 The FS representation of the full-wave rectified sine wave x(t) = | sin(t)| is
∞
2 4 1
x(t) = + cos(2kt)
π π 1 − 4k 2
k=1
2 4 4 4
= − cos(2t) − cos(4t) − cos(6t) + · · ·
π 3π 15π 35π
Using the time-shift property, find the FS representation of the full-wave rectified
cosine wave x(t) = | cos(t)|.
7.4.2 Find the convolution y(t) of x(t) = sin(t + π3 ) and h(t) = sin(t − π6 ) using the
FS time-domain convolution theorem. Verify the answer by directly convolving x(t)
and h(t) in the time domain.
7.4.3 Using the time-differentiation property, find the derivative of x(t) = 2 sin(3t).
7.5
Compute the FS coefficients of x(t), using the DFT, with the sampling interval equal
to 1 and 0.8 s. Compare the result with Eq. (7.18).
7.5.1
2π π 2π π
x(t) = 1 + sin t− + cos 2 t −
4 3 4 3
* 7.5.2
2π π 2π π
x(t) = 3 + sin t− + sin 2 t +
4 6 4 3
7.5.3
2π π 2π π
x(t) = 2 + cos t− + cos 2 t +
4 4 4 4
Chapter 8
The Discrete-Time Fourier Transform
The DTFT is the dual of the FS. In the FS representation of signals, the time-domain
waveform is continuous and periodic and the spectrum is discrete and aperiodic. In
the DTFT representation of signals, the spectrum is continuous and periodic and
the time-domain waveform is discrete and aperiodic. Another difference is that the
continuous signal is usually real and the discrete spectrum is complex in the FS. On
the other hand, the continuous spectrum is complex and the discrete signal is usually
real in the DTFT. By interchanging the roles of time-domain and frequency-domain
variables, we can obtain one representation from the other. However, it is better to
derive the DTFT as the limiting case of the DFT, as the period of the time-domain
sequence tends to infinity with the sampling interval fixed. The effective frequency
range of the spectrum is fixed by the sampling interval. In other than the DFT version
of the Fourier analysis, the signal or the spectrum or both are of continuous type. In
the Fourier analysis and synthesis definitions, the summation in the DFT becomes
an integral for continuous type of signals and spectra. Basically, Fourier analysis,
despite the differences between the versions, is always the decomposition of an
arbitrary signal in terms of sinusoidal waveforms.
The DTFT, X (ejω ), of the sequence x(n), with the sampling interval Ts = 1, is defined
by the infinite summation
∞
X (ejω ) = x(n)e−jωn (8.1)
n=−∞
The exponential ejω in X (ejω ) emphasizes the fact that it is a periodic function of ω.
The frequency-domain representation is a complex function of ω and is periodic in
ω with period 2π/Ts = 2π, since e−j(ω+2π)n = e−jωn . The inverse DTFT, x(n), of the
spectrum X (ejω ) is defined by the integral over one period of X (ejω ) as
π
1
x(n) = X (ejω )ejωn d ω, n = 0, ±1, ±2, . . . (8.2)
2π −π
The infinite time-domain sequence x(n) is the FS for the continuous periodic spectrum
X (ejω ).
Example 8.1 Find the DTFT of x(n). The nonzero samples are {x(−1) = 1,
x(1) = 1}.
Solution
From the definition,
X (ejω ) = ejω + e−jω = 2 cos(ω)
since π
1 for k = 0
e jωk
dω =
−π 0 for k = ±1, ±2, . . .
One period of the magnitude spectrum |X (ejω )| of x(n) and the phase spectrum
∠X (ejω ) is shown in Fig. 8.1a, b, respectively.
(a) (b)
2 180
Period = 2
X(e j ), degrees
|X(e j )|
0 -180
0 0
Fig. 8.1 a The magnitude spectrum |X (ejω )| for x(n) and b the phase spectrum
8.1 The DTFT 219
In this section, we derive the DTFT as a limiting case of the DFT by letting the period
of the time-domain sequence tends to infinity with the sampling interval fixed. As in
the case of the FS, we start with the IDFT expression and substitute the expression
for X (k) in that. We use the center-zero format for convenience. Let the DFT of
sequence x(n), N ≤ n ≤ N be X (k), N ≤ k ≤ N . Then, the Fourier representation
of x(n) is given as
1
N
2π
x(n) = X (k)ej (2N +1) nk , n = 0, ±1, ±2, . . . , ±N (8.3)
2N + 1
k=−N
where
N
x(m)e−j (2N +1) mk
2π
X (k) = (8.4)
m=−N
2π
→0
(2N + 1)
and the spectrum becomes continuous with the same period, as Ts is fixed.
The discrete and periodic time-domain sequence becomes discrete and aperiodic
and the discrete and periodic spectrum becomes continuous and periodic. Then, the
220 8 The Discrete-Time Fourier Transform
The outer summation becomes an integral with limits −π and π. As the spectrum is
periodic, the limits could be any continuous interval of 2π. Therefore, the synthesis
expression of the DTFT becomes
π
1
x(n) = X (ejω )ejωn d ω, n = 0, ±1, ±2, . . . (8.7)
2π −π
The analysis equation of the DTFT is a summation, since the time-domain signal is
discrete. The synthesis equation is an integral, since the spectrum is continuous.
Consider the signal x(n) with N = 5 nonzero samples and its DFT spectrum,
shown in Fig. 8.2a, b, respectively. The sampling interval is Ts = 1 and the fre-
quency increment is 2π/5 radians per sample. With the same Ts = 1, consider the
signal x(n) with N = 9 and its DFT spectrum, shown in Fig. 8.2c, d, respectively.
The sampling interval is Ts = 1 and the frequency increment is 2π/9 radians per
sample. The time-domain range is increased making the record length longer and the
frequency increment is decreased making the spectrum denser. With 9 independent
samples in the time domain, there can only a maximum of 9 independent samples
in the frequency domain. Remember that complex spectrum of real-valued signals
is redundant by a factor of 2. With N = 17 samples, the record length is longer and
the spectrum is denser, as shown in Fig. 8.2e, f. As N → ∞, the time-domain signal
becomes aperiodic. The frequency increment tends to zero and, therefore, the cor-
responding spectrum becomes continuous. The DTFT spectrum is shown by a solid
line.
In all the versions of the Fourier analysis, for certain values of the frequency
index or the time index, the expressions for the forward and inverse transforms take
a simplified form. Consequently, the values with index such as zero or π can be
computed easily. These values are useful to check the correctness of the closed-form
expressions for x(n) or X (ejω ).
∞
∞
π
1
X (ej0 ) = x(n), X (ejπ ) = (−1)n x(n), x(0) = X (ejω )d ω,
n=−∞ n=−∞
2π −π
The DTFT definitions for the forward and inverse transforms, in Eqs. (8.6) and
(8.7), have been derived assuming that the sampling interval of the time-domain
signal, Ts , is one second. With the scaling of the frequency axis, the transform values
8.1 The DTFT 221
(a) 1 (b) 5
X(k)
x(n)
N=5
0
0
-2 -1 0 1 2 - 0
n k
(c) 1 (d) 5
X(k)
x(n)
N=9
0
0
-4 -2 0 2 4 - 0
n k
(e) (f) 5
1
X(k)
N=17
x(n)
0
0
-8 -4 -2 0 2 4 8 - 0
n k
Fig. 8.2 a The time-domain signal x(n) with N = 5 and b its DFT spectrum, |X (k)|; c the time-
domain signal x(n) with N = 9 and d its DFT spectrum, |X (k)|; e the time-domain signal x(n) with
N = 17 and f its DFT spectrum, |X (k)|. The DTFT spectrum is shown by a solid line
for any other values of Ts can be easily found. However, with Ts = 1, the DTFT and
its inverse can also be redefined including Ts as
∞
X (ejωTs ) = x(nTs )e−jnωTs (8.8)
n=−∞
ωs
1 2
x(nTs ) = X (ejωTs )ejnωTs d ω, n = 0, ±1, ±2, . . . , (8.9)
ωs − ω2s
where ωs = 2π Ts
. The plot of the spectrum over the half period from ω = 0 to ω = π/Ts
is adequate for real-valued signals.
In the case of the DFT and the FS, the frequency of the harmonic components
is discrete and, hence, the reconstruction of the waveforms is easy to visualize.
However, in the case of the DTFT and FT, the synthesis process is not apparent,
222 8 The Discrete-Time Fourier Transform
since all the frequency components in the range of frequencies contribute. The DTFT
synthesizes a discrete aperiodic signal, x(n), as integrals of a continuum of complex
sinusoids ejωn (amplitude 2π 1
X (ejω )d ω) over the finite frequency range −π to π,
which is one period of X (e ). As the amplitude of the constituent sinusoids of
jω
The summation converges in the least squares error sense, if x(n) is square summable.
That is,
∞
|x(n)|2 < ∞
n=−∞
Since the spectrum is of finite duration, the power spectrum is integrable and the
energy is finite. Gibbs phenomenon occurs in constructing the continuous spectrum,
if x(n) is not absolutely summable.
Example 8.2 Determine the DTFT of the unit impulse signal x(n) = δ(n).
Solution
From the DTFT definition, we get
∞
X (ejω ) = δ(n)e−jωn = 1 and δ(n) ↔ 1
n=−∞
Since δ(n) is zero except at n = 0 and the value of the exponential equals 1 at that
point, the summation yields a value of unity for all values of ω. The transform
of the impulse is a constant. Therefore, the unit impulse signal is composed of
complex sinusoids of all the infinite frequencies from ω = −π to ω = π with equal
strength.
Example 8.3 Find the DTFT spectrum of the signal
(a) (b)
1 11
X(e j )
x(n)
period=2
0
0 -1
-10 -5 0 4 10 - -- 0 -
n 4 4
Using the formula for the geometric sum for complex sequences
N
1 − z (N +1)
zn = , z = 1
1−z
k=0
we get
1 − e−j6ω 1 − ej6ω
X (ejω ) = −jω
+ −1
1−e 1 − ejω
As the first two terms are complex conjugates, their sum is equal to twice the real
part of either of the terms. Therefore,
6
2 ω cos 2 ω
5
2 sin
2 ω +
sin 11 sin ω2 sin 112 ω
X (e ) =
jω ω −1= − 1 = , −π < ω < π
sin 2 sin ω2 sin ω2
shown in Fig. 8.3b, as the DTFT of a pulse of width 11 samples, is called the sinc
function, a function of great significance in signal and system analysis. The sinc
function is even-symmetric. The peak value 11 occurs at ω = 0, since
lim sin(θ) = θ
θ→0
224 8 The Discrete-Time Fourier Transform
(a) (b)
1 21
X(e j )
x(n)
period=2
0
0
-10 -5 0 4 10 - 0
- - -
n 4 4
(c) (d) 41
1
X(e j )
x(n)
period=2
0
0
-20 -10 0 10 20 - 0
- - -
n 4 4
Fig. 8.4 a x(n) = u(n + 10) − u(n − 10); b its DTFT spectrum; c x(n) = u(n + 20) − u(n − 20);
d its DTFT spectrum
With N increasing, the function becomes taller and slimmer and the area enclosed
is concentrated around ω = 0. As N → ∞, the time-domain function becomes the
DC function. The frequency-domain function
(2N +1)
sin 2
ω
ω
sin 2
degenerates into an impulse function with strength 2π, as the zeros move to ω = 0.
That is, all the oscillations and the large hump coincide at ω = 0 and the net area of
the function occurs at that point, which characterizes an impulse. The sinc function
is an energy signal, as it is square integrable. But it is not absolutely integrable.
Therefore, the DTFT transform pair for the DC signal is
1 ↔ 2πδ(ω)
8.1 The DTFT 225
Example 8.4 Find the DTFT of the signal x(n) = an u(n), |a| < 1.
Solution
∞
∞
1
X (ejω ) = an u(n)e−jωn = (ae−jω )n = , |a| < 1
n=0 n=0
1 − ae−jω
The middle summation is a geometric progression with ratio ae−jω < 1, since |a| < 1
and |e−jω | = 1. Using the Euler’s formula, we get
1
X (ejω ) =
1 − a cos(ω) + ja sin(ω)
The exponential signals 0.5n u(n) and (−0.5)n u(n) and their magnitude and phase
spectra are shown in Fig. 8.5a–f. The magnitude spectra are even-symmetric and
the phase spectra are odd-symmetric. Signal in (a) is smoother and, therefore, the
magnitude of low frequency components is high. On the other hand, signal in (b) is
more fluctuating and, therefore, the magnitude of high frequency components is high.
Let us derive the DTFT spectrum of sgn signal by considering this signal as sum of
two exponentials in the limit as a → 1. It is an everlasting signal. For positive values
of its argument it is the same as u(n), the unit-step function. Otherwise, its values are
equal to −1. Figure 8.6a, b show the signal x(n) = 0.8n u(n) − 0.8−n u(−n) + δ(n)
and its real and imaginary parts of the DTFT spectrum. Figure (c) and (d) show
the signal x(n) = 0.99n u(n) − 0.99−n u(−n) + δ(n) and its real and imaginary parts
of the DTFT spectrum. As the base of the exponentials approach 1, the sum of the
exponentials approaches the sgn function. Consider the transform
1 1 1 − 2aejω + a2
X (ejω ) = − + 1 =
1 − ae−jω 1 − aejω (1 − ae−jω )(1 − aejω )
226 8 The Discrete-Time Fourier Transform
(a) (b)
1 1
x(n)
0
0
0 4 8 0 4 8
n n
(c) (d)
2.0000 2.0000
|X(e j )|
|X(e j )|
0.6667 0.6667
- 0 - 0
- - - - - -
2 2 2 2
(e) (f)
0.5236 0.5236
X(e j )
X(e j )
0 0
-0.5236 -0.5236
- 0 - 0
- - - - - -
2 2 2 2
Fig. 8.5 a x(n) = 0.5n u(n); b x(n) = (−0.5)n u(n); c the magnitude of the DTFT spectrum of the
signal in a and e its phase spectrum; d the magnitude of the DTFT spectrum of the signal in b and
f its phase spectrum
The inverse DTFT of this spectrum is the sgn function, called signum function,
sgn(n).
8.1 The DTFT 227
(a) (b)
1 4.4444
X(e j )
1
x(n)
period=2
-4.4444
-10 -5 0 4 10 - 0
- - -
n 4 4
(c) (d)
1 318.2789
X(e j )
x(n)
0 1
period=2
-1 -318.1776
-10 -5 0 4 10 - 0
- - -
n 4 4
Fig. 8.6 a x(n) = 0.8n u(n) − 0.8−n u(−n) + δ(n) and b its real (dashed line) and imaginary parts
of the DTFT spectrum; c x(n) = 0.99n u(n) − 0.99−n u(−n) + δ(n) and d its real and imaginary
parts of the DTFT spectrum
(a) (b)
0.5 1
sgn(n)
u(n)
DC
0 0.5
-0.5 0
-20 -10 0 10 20 -20 -10 0 10 20
n n
Fig. 8.7 a The sign function 0.5sgn(n); b u(n) and x(n) = 0.5
Figure 8.7a shows the sgn function multiplied by 0.5, 0.5sgn(n). Figure 8.7b shows
the unit-step function u(n) and the DC function x(n) = 0.5. The DC function is the
even component of u(n) and 0.5sgn(n) is the odd component of u(n). Therefore,
and the DTFT pair for u(n), due to linearity property of the DTFT, is
1
u(n) ↔ πδ(n) +
1 − e−jω
228 8 The Discrete-Time Fourier Transform
Therefore, the DTFT of Aejω0 n is 2πAδ(ω − ω0 ), −π < ω < π. The DTFT spectrum
is periodic with period 2π. Therefore, the DTFT of a periodic signal is a periodic
train of impulses with strength 2π
N
X (k) at 2π
N
k with period 2π.
For example, consider the DFT pair
2π
sin n ↔ {X (0) = 0, X (1) = −j2, X (2) = 0, X (3) = j2}
4
The DTFT and the DFT of a finite sequence x(n) of length N are given as
+N −1
n0 +N −1
n0
x(n)e−jωn and X (k) = x(n)e−j N kn ,
2π
X (ejω ) =
n=n0 n=n0
where n0 is the starting point of x(n). The DTFT is evaluated at all frequencies on
the unit circle from −π to π, whereas the DFT is evaluated at the set of discrete
frequencies 2πk/N . Therefore,
2π
at ω = 2π
4
k, k = 0, 1, 2, 3 is the DFT of x(n).
It is often of interest to know the effect of an operation in the time domain corre-
sponding to that in the frequency domain or vice versa. Properties help us to find the
transforms with less effort. In addition, the DTFT of related signals can be found
easily from those known.
8.2.1 Linearity
The DTFT of a linear combination of two or more signals is equal to the same linear
combination of the DTFT of the individual signals. That is,
where p and q are arbitrary constants. As the DTFT is defined by the summation
operation, which is linear, the DTFT has the linearity property. We used this property
in deriving the DTFT of the unit-step signal from those of the sgn and DC signals.
Shifting a signal x(n) in the time domain by ±n0 sample intervals results in x(n ±
n0 ). The shifting does not affect the magnitude of the signal. But the phases of its
constituent sinusoidal components are changed in proportion of their frequencies.
By directly substituting x(n ± n0 ) for x(n) in the DTFT definition, we get
Let the signal x(n) with DTFT X (ejω ) be multiplied by the exponential e±jω0 n to
become x(n)e±jω0 n . Then, combining the two exponentials in the summand of the
DTFT definition for this signal, we get e−j(ω∓ω0 ) . The result is that the independent
variable ω in X (ejω ) is replaced by ω ∓ ω0 . The resulting DTFT is X (ej(ω∓ω0 ) ). That is,
x(n)e±jω0 n ↔ X (ej(ω∓ω0 ) )
1 1 1
−jω
and −j(ω+π)
=
1 − (0.5)e 1 − (0.5)e 1 + (0.5)e−jω
∞
π
1
x(m)h(n − m) = X (ejω )H (ejω )ejωn d ω ↔ X (ejω )H (ejω )
m=−∞
2π −π
8.2 Properties of the Discrete-Time Fourier Transform 231
(a) (b) 5
1
period=2
n
|X(e j )|
0.8 u(n)
x(n)
0
0
-8 -6 -4 -2 0 2 4 6 8 - 0
n
(c) (d)
2 25
period=2
x(n)*x(n)
|X 2(e j ) |
(n+1)0.8 n u(n)
0
0
-8 -6 -4 -2 0 2 4 6 8 - 0
n
Fig. 8.8 a The exponential signal 0.8n u(n) and b its spectrum. c The signal 0.8n u(n) ∗ 0.8n u(n) =
(n + 1)0.8n u(n) and d its spectrum
Consider convolution of the exponential signal 0.8n u(n) with itself. The signal
and its DTFT spectrum are shown in Fig. 8.8a, b, respectively. The DTFT of the
signal and that of its convolution with itself are
1 1
−jω
and
1 − 0.8e (1 − 0.8e−jω )2
The signal (n + 1)0.8n u(n) and its spectrum are shown, respectively, in Fig. 8.8c, d.
8.2.5 Correlation
The transform of the product of two time-domain signals is the convolution of their
individual transforms in the frequency domain with a scale factor. In the case of
the FS, as the transform is discrete, the visualization of this operation is easy. For
all purposes, the discrete spectrum is easier to interpret. When the transform is
continuous, while we anticipate the result, the visualization is not so easy. Therefore,
we have to use formal procedure in deriving the result.
Consider the DTFT representations of x(n) and y(n)
π π
1 1
x(n) = X (eju )ejun du and y(n) = Y (ejv )ejvn d v
2π −π 2π −π
The DTFT of x(n)y(n) is to be expressed in terms of those of x(n) and y(n). The
DTFT representation of x(n)y(n) is
π π
1 1
x(n)y(n) = X (eju )Y (ejv )ej(u+v)n du d v
2π −π 2π −π
That is,
∞
π
1
x(n)y(n) ↔ x(n)y(n)e−jωn = X (eju )Y (ej(ω−u) )du
n=−∞
2π −π
1
X (ejω ) =
1 − 0.64e−jω
8.2 Properties of the Discrete-Time Fourier Transform 233
|X(e j )|
0.64 n u(n)
x(n)
0
0
-8 -6 -4 -2 0 2 4 6 8 - 0
n
Fig. 8.9 a The exponential signal 0.8n u(n)0.8n u(n) = 0.64n u(n) and b its spectrum
While it is easier to find the DTFT in this case, for an arbitrary signal, we have to
use this property. For this example,
2π
1 1 1
X (ejω ) = du
2π 0 1 − 0.8e−ju 1 − 0.8e−j(w−u)
The inverse DTFT of X (ejω ) is x(n) = 0.64n u(n). In practice, samples of the functions
are obtained and the convolution is computed numerically.
8.2.7 Symmetry
Therefore, X ∗ (e−jω ) = X (ejω ), called the conjugate symmetry. That is, if a signal is
real, then the real part of its spectrum X (ejω ) is even-symmetric and the imaginary
part is odd symmetric. Equivalently, the magnitude spectrum is even-symmetric and
the phase spectrum is odd symmetric.
234 8 The Discrete-Time Fourier Transform
A real and even signal has a real and even-symmetric spectrum. Since x(n) cos(ωn)
is even and x(n) sin(ωn) is odd, the imaginary part is zero. Therefore,
∞
π
1
X (ejω ) = x(0) + 2 x(n) cos(ωn) and x(n) = X (ejω ) cos(ωn)d ω
n=1
π 0
For example,
A real and odd signal has an imaginary and odd symmetric spectrum. Since
x(n) cos(ωn) is odd and x(n) sin(ωn) is even, the real part is zero. Therefore,
∞
π
j
X (ejω ) = −j2 x(n) sin(ωn) and x(n) = X (ejω ) sin(ωn)d ω
n=1
π 0
For example,
{x(−1) = 1, x(0) = 0, x(1) = −1} ↔ j2 sin(ω)
8.2.8 Time-Reversal
Let both the variables ω and n are replaced by −ω and −n in the DTFT definition
∞
X (ejω ) = x(n)e−jωn
n=−∞
Then, the exponent of e remains the same. But, X (ejω ) and x(n) are replaced by
X (e−jω ) and x(−n). The change in the signs of the limits does not affect the summa-
tion. Therefore,
x(n) ↔ X (ejω ) → x(−n) ↔ X (e−jω )
8.2 Properties of the Discrete-Time Fourier Transform 235
For example,
8.2.9 Time-Expansion
Let
x(n) ↔ X (ejω )
xu (n) = x(n) if n
a
is an integer and xu (n) = 0 otherwise
Therefore,
xu (n) ↔ X (ejaω )
The spectrum of the expanded signal is a compressed version of that of the original.
The spectral value at ω in the original spectrum occurs at ω/a in the spectrum of
its expanded version. With a negative, the spectrum is also frequency-reversed, in
addition.
For example, the DTFT of the signal x(n) shown in Fig. 8.10a with dots, with its
only nonzero values given as x(−1) = 1 and x(1) = 1, is X (ejω ) = ejω + e−jω =
2 cos(ω). Using the theorem, we get the DTFT of xu (n) with a = 3, shown in
Fig. 8.10a with cross, as
(a) (b) 2
1
X(e j ),X u(e j )
x(n),x u (n)
0 -2 Period=2
-5 -4 -3 -2 -1 0 1 2 3 4 5 - 0
n
Fig. 8.10 a Signal x(n) (dots) and its expanded version xu (n) (cross) with a = 3, and b the DTFT
of x(n) (solid line) and that of xu (n) (dashed line)
236 8 The Discrete-Time Fourier Transform
This result is obvious from the DTFT definition. The DTFT of the signal (solid
line) and that of its expanded version (dashed line) are shown in Fig. 8.10b. Since the
signal is expanded by a factor of three, its spectrum is compressed by a factor of three.
Since an expanded signal varies more slowly, the frequencies of its components are
lowered, implying a compressed spectrum.
8.2.10 Frequency-Differentiation
The DTFT spectrum X (ejω ) of x(n) can be differentiated with respect to ω, as long
as the resulting functions have DTFT representations. By differentiating both sides
of the DTFT defining equation, with respect to ω, we get
dX (ejω ) dX (ejω )
(−jn)x(n) ↔ or (n)x(n) ↔ (j)
dω dω
d k X (ejω ) d k X (ejω )
(−jn)k x(n) ↔ or (n)k x(n) ↔ (j)k
dω k d ωk
Consider the transform pair
8.2.11 Summation
Let
x(n) ↔ X (ejω )
Then,
n
X (ejω )
x(k) ↔ + πX (ej0 )δ(ω), −π < ω ≤ π
(1 − e−jω )
k=−∞
8.2 Properties of the Discrete-Time Fourier Transform 237
As the unit-step signal is 1 for positive values of its argument and zero otherwise,
1 for k ≤ n
u(n − k) =
0 for k > n
n
jω
x(n) ∗ u(n) = x(k) ↔
1
+ πδ(ω) X (e jω ) = X (e ) + πX (ej0 )δ(ω)
(1 − e−jω ) (1 − e−jω )
k=−∞
n
1
u(n) = δ(k) ↔ + πδ(ω), −π < ω ≤ π
(1 − e−jω )
k=−∞
As an another example, consider the signal x(n) = u(n) − u(n − 3), shown in
Fig. 8.11a, and the resulting signal, shown in Fig. 8.11b, obtained by summing it.
The DTFT of the given signal is, from the DTFT definition, 1 + e−jω + e−j2ω . Using
the property, we get the DTFT of its summation as
1 + e−jω + e−j2ω
+ 3πδ(ω), −π < ω ≤ π
1 − e−jω
(a) 1 (b) 3
2
x(n)
y(n)
0 0
-4 -2 0 1 2 3 4 -4 -2 0 1 2 3 4
n n
n
Fig. 8.11 a Signal x(n) = u(n) − u(n − 3); b y(n) = k=−∞ x(k)
238 8 The Discrete-Time Fourier Transform
The energy of a signal can also be expressed in terms of its spectrum, which is an
equivalent representation.
∞
2π
1
E= |x(n)|2 = |X (ejω )|2 d ω
n=−∞
2π 0
The energy of the signal x(−1) = 1, x(1) = 1 is 2. Its DTFT is 2 cos(ω). From
its DTFT, the energy is
2π 2π
1 1
E= |2 cos(ω)|2 d ω = (1 + cos(2ω))d ω = 2
2π 0 π 0
In the frequency domain, the transfer function H (ejω ) relates the input and output
of a LTI system as
Y (ejω ) = H (ejω )X (ejω )
where X (ejω ), Y (ejω ), and H (ejω ) are the DTFT of the input, output, and impulse
response of the system. The output energy spectrum is given by
As it relates the input and output energy spectral densities of the input and output
of a system, |H (ejω )|2 is called the energy transfer function. The quantity, such as
|X (ejω )|2 , is the energy spectral density of the signal x(n), since 2π
1
|X (ejω )|2 d ω is
the signal energy over the infinitesimal frequency band ω to ω + d ω.
8.3 Applications
where x(n), h(n), and y(n) are, respectively, the system input, impulse response, and
output, and X (ejω ), H (ejω ), and Y (ejω ) are their respective transforms. As multiplica-
tion of the input with H (ejω ) yields the output, H (ejω ) is called the transfer function
of the system. The transfer function is the transform of the impulse response. It char-
acterizes a system in the frequency domain just as the impulse response does in the
time domain.
The spectrum of the impulse function is a constant. It is composed of complex
exponentials, ejωn , of all frequencies from ω = −π to ω = π with equal magnitude
and zero phase. Therefore, the transform of the impulse response, the transfer func-
tion, is also called the frequency response of the system. Consequently, an exponential
Aej(ωa n+θ) or a real sinusoidal input signal A cos(ωa n + θ) is changed to, respectively,
(|H (ejωa )|A)ej(ωa n+(θ+∠(H (e ))) or (|H (ejωa )|A) cos(ωa n + (θ + ∠(H (ejωa ))) at the
jωa
output. The steady-state response of a stable system to the causal input Aej(ωa n+θ) u(n)
is also the same. Since,
Y (ejω )
H (ejω ) = ,
X (ejω )
the transfer function can also be described as the ratio of the transform Y (ejω ) of the
output y(n) to that of the input x(n), X (ejω ). It is assumed that |X (ejω )| = 0 for all
frequencies of interest.
Using the time-shift property of the DTFT, a difference equation with constant
coefficients can be reduced to an algebraic equation that can be solved for Y (ejω ).
Then, the inverse DTFT of Y (ejω ) yields the system output y(n). Consider the dif-
ference equation of a causal LTI discrete system
Taking the DTFT of both sides, we get, assuming initial conditions are all zero,
Example 8.6 Find the response, using the DTFT, of the system governed by the
difference equation
y(n) = x(n) + 0.8y(n − 1)
Substituting ω = 2π
8
, we get
2π
2π
ej 8
H ej 8 = 2π = 1.4022∠(−0.9160)
ej 8 − 0.8
Example 8.7 Find the impulse response h(n), using the DTFT, of the system gov-
erned by the difference equation
5 1
y(n) = x(n) − 2x(n − 1) + x(n − 2) + y(n − 1) − y(n − 2)
6 6
Solution
3 8
H (ejω ) = 6 + 1 −jω
−
1 − 2e 1 − 13 e−jω
Example 8.8 Find the zero-state response, using the DTFT, of the system governed
by the difference equation
2
Y (ejω ) = H (ejω )X (ejω ) =
(1 − 0.6e−jω )(1 − 0.5e−jω )
12 10
Y (ejω ) = −
(1 − 0.6e−jω ) (1 − 0.5e−jω )
Filters are required in signal processing systems to suppress or modify some part
of the spectrum of the input signal in a desired way. As a linear system, the filter
is characterized by its impulse response in the time domain and frequency response
in the transform domain. Usually, the filter is specified in terms of the required
frequency response and the task is to determine the impulse response. One of the
simpler methods of FIR filter design is called the window method. In this method,
the impulse response of the desired filter is found by finding the inverse DTFT of the
specified frequency response.
242 8 The Discrete-Time Fourier Transform
For example, the input and the output of the differentiator are
(a) j (b) j
H(e j )
H(e j )
0 0
period=2 period=2
-j -j
- 0 - 0
Fig. 8.12 a The frequency response of the ideal digital differentiator. b The frequency response of
the ideal Hilbert transformer
8.3 Applications 243
The DFT version of the Hilbert transform is presented in Chap. 5. We just present
its DTFT periodic frequency response, shown in Fig. 8.12b over one period, of the
ideal Hilbert transformer defined as
−j for 0 < ω < π
H (e ) =
jω
j for −π < ω < 0
The impulse response of the ideal Hilbert transformer is obtained by finding the
inverse DTFT of its frequency response.
π 0
1 1
h(n) = −je jωn
dω + jejωn d ω
2π 0 2π −π
2 sin2 ( πn
2 )
= πn
for n = 0 , −∞ < n < ∞
0 for n = 0
8.3.5 Downsampling
DTFT and DFT versions of the Fourier analysis are mostly used in multirate digital
signal processing applications. Downsampling and upsampling are the two basic
operations in multirate digital signal processing. Upsampling is presented in the
DTFT properties section. Consider the signal x(n). Retaining one out of every D
samples, starting from n = 0, and discarding the rest is called the downsampling of a
signal by a factor of D, a positive integer. The nth sample of the downsampled signal
xd (n) is the (Dn)th sample of x(n)
xd (n) = x(Dn)
244 8 The Discrete-Time Fourier Transform
1 1
x(n) + (−1)n x(n) ↔ X (ejω ) + X (ej(ω+π) ) (8.10)
2 2
For example,
Now,
1
x(n) + (−1)n x(n) = {x(0) = 2, x(1) = 0, x(2) = 3, x(3) = 0}
2
1
↔ X (ejω ) + X (ej(ω+π) ) = 2 + 3e−j2ω
2
The term 3e−j2ω is periodic with period π (3e−j2(ω+π) = 3e−j2π e−j2ω = 3e−j2ω ) and
the constant term 2 is periodic with any period. Therefore, the spectrum is periodic
with period π. Now, if the take the spectral values {5, −1} over one period and
compute the IDFT, we get {2, 3}, which is the downsampled version of x(n). The
spectrum of {2, 3}, by definition, is 2 + 3e−jω , which can also be obtained from
2 + 3e−j2ω by replacing ω by ω/2. Due to upsampling, if the DTFT of {a, b} is
Y (ejω ) then the DTFT of the upsampled signal {a, 0, b, 0} is the concatenation and
compression of Y (ejω ) and Y (ejω ) in the range 0 < ω < 2π, Y (ej2ω ). The spectrum
is replicated. Therefore, by replacing ω by ω/2 in Eq. (8.10), we take the values of
the spectrum of the upsampled signal in the frequency range from 0 to π only and
expand it in forming the spectrum Xd (ejω ) of the downsampled signal
1 jω ω
In learning and understanding Fourier analysis or other transforms, we find the trans-
form of well-defined signals, such as a pulse, an exponential, a triangular etc., ana-
lytically. However, practical signals usually have arbitrary amplitude profile and they
have to be approximated by a set of discrete samples enabling the use of software or
digital hardware in their analysis.
Both the DFT and the DTFT spectra are periodic with period 2π. The DTFT
spectrum is continuous, while the DFT spectrum is composed of uniform samples of
the DTFT spectrum. Sampling the spectrum implies periodicity of the time-domain
signal. That is, if all the time-domain samples of a signal are contained in a period,
the samples can be obtained exactly from the samples of the DTFT spectrum by
using the DFT. Otherwise, time-domain aliasing occurs.
Let
x(n) = {x(0) = 2, x(1) = 1, x(2) = 3, x(3) = 4}
The 4-point DFT of x(n) is the same. The IDFT of these samples yields x(n). With
just 2 spectral samples {10, 0}, the IDFT yields {5, 5}. Time-domain aliasing has
occurred. In practice, aliasing in unavoidable due to the finite and infinite natures,
respectively, of the DFT and the DTFT in the time domain. With 5 spectral samples
The conclusion is that exact time-domain samples can be obtained from the samples
of the DTFT spectrum with time-limited signals. Otherwise, it has to be ensured that
time-domain aliasing is negligible.
In approximating the samples of the DTFT spectrum by using the DFT, the prob-
lem is data truncation. The input time-domain samples are usually too long and
truncation is required to limit the size of the data to limit the computational com-
plexity and memory requirements of the DFT. The data has to be truncated so that
sufficient energy of the signal is retained in the truncated signal. Another point is
that the samples may be specified over any time-domain range, while DFT algo-
rithms usually require them to be specified from n = 0 to n = N − 1 for a N -point
246 8 The Discrete-Time Fourier Transform
signal. This can be achieved due to the assumed periodicity of the DFT. Further, zero
padding may be required to make the length equal to an integral power of 2.
Let
x(n) = {x(−1) = −2, x(0) = 1, x(1) = 3}
This is the DFT of the circular convolution of a rectangular window and that of xp(n)
divided by 3. The DFT of xp(n) is
We want the circular convolution output, which can be obtained by adding the last
two terms with the first two terms.
8.5 Summary
• The DTFT version of the Fourier analysis is used to analyze aperiodic discrete
signals. The corresponding spectrum is continuous and periodic and it is a relative
amplitude spectrum.
8.5 Summary 247
• The DTFT is the dual of the FS with the roles of the time- and frequency domains
interchanged. The aperiodic discrete sequence is the FS of the continuous periodic
spectrum in the frequency domain.
• The DTFT is the limiting case of the DFT as the period of the time-domain sequence
tends to infinity with the sampling interval fixed.
• As the DTFT represents sampled waveforms, its spectrum is periodic. Periodicity
of the spectrum implies that the effective range of the frequencies in the spectrum
is finite.
• As the DTFT is defined by an infinite sum, the infinite samples is absolutely or
square summable is a sufficient condition for its existence.
• As with the other versions of the Fourier analysis, the DTFT is also effectively
approximated by the DFT in practical applications.
• The DTFT is widely used in the analysis of discrete signals and stable LTI systems.
The DTFT of the impulse response of a system is its frequency response.
Exercises
2π π
8.1 Find the DTFT of sin 8
n+ 6
.
* 8.2 Find the inverse DTFT of j2 sin(2ω).
8.3 Given the nonzero samples of a signal,
2
y(n) = x(n) + 3x(n − 1) + 2x(n − 2) + y(n − 1) − y(n − 2)
9
* 8.8 Find the zero-state response, using the DTFT, of the system governed by the
difference equation
y(n) = x(n) − 0.6y(n − 1)
8.9 Find the DTFT Xd (ejω ) of the downsampled version xd (n) of x(n), by a factor of
2, in terms of its DTFT X (ejω ).
8.9.1
x(n) = (0.8)n u(n)
8.9.2
2π
x(n) = cos n
8
8.9.3
1 for −3 ≤ n ≤ 3
x(n) =
0 otherwise
8.10 Given 4 samples of x(n), find its DTFT X (ejω ) analytically. Find the DFT of one
period xp(n), n = 0, 1, 2, 3 obtained by periodically extending x(n). Verify that the
uniform samples of X (ejω ) and the DFT are the same. Truncate xp(n) by a window
{w(0) = 1, w(1) = 1, w(2) = 1, w(3) = 0} to get xp_t(n). Find the DFT of xp_t(n)
and justify it in terms of the DFT of w(n) and xp(n).
* 8.10.1
{x(−2) = 2, x(−1) = 1, x(0) = 3, x(1) = 4}
8.10.2
{x(−1) = 1, x(0) = 1, x(1) = 3, x(2) = 3}
8.10.3
{x(−3) = 2, x(−2) = 4, x(−1) = 3, x(0) = 1}
8.11 Given 4 samples of x(n), find its DTFT X (ejω ) analytically. Find the 4 uniform
samples of X (ejω ) and compute the IDFT and verify that we get back x(n). Find the
3 and 5 uniform samples of X (ejω ) and compute the respective IDFT and justify the
result in terms of x(n).
8.11.1
{x(0) = 3, x(1) = 1, x(2) = 3, x(3) = 4}
8.11.2
{x(0) = 1, x(1) = 2, x(2) = 3, x(3) = 4}
8.11.3
{x(0) = 3, x(1) = 1, x(2) = 2, x(3) = 4}
Chapter 9
The Fourier Transform
The Fourier transform (FT) is the most general version of the Fourier analysis. It is
primarily used for the representation of continuous aperiodic signals with continuous
aperiodic spectra. In addition, it is the tool to analyze mixed class of signals as it
can represent signals represented by other versions of the Fourier analysis. It can
be considered as an extension of the DTFT. As the sampling interval tends to zero,
the time-domain signal becomes continuous and the continuous periodic spectrum
becomes continuous and aperiodic. It can also be considered as an extension of
the FS as the period of the periodic signal tends infinity. The time-domain signal
corresponding to a discrete spectrum is periodic. On the other hand, the time-domain
signal corresponding to a continuous spectrum is aperiodic.
Consider the FS synthesis and analysis expressions derived in Chap. 7 for a contin-
uous periodic signal x(t) with period T .
∞
x(t) = Xfs (k)ejω0 tk (9.1)
k=−∞
and
T /2 T /2
1 ω0
Xfs (k) = x(t)e−jω0 tk dt = x(t)e−jω0 tk dt (9.2)
T −T /2 2π −T /2
and
T /2
TXfs (k) = x(t)e−jω0 tk dt (9.4)
−T /2
At the end of the limit process, we get the FT and IFT expressions. The FT X ( jω)
of x(t) is defined as ∞
X ( jω) = x(t)e−jωt dt (9.5)
−∞
Figure 9.1a, b show a square pulse with period 2π and its FS spectrum with the
fundamental frequency ω0 = 1 rad. The corresponding scaled FT is also shown in
a solid line. Figure 9.1c, d show the square pulse with period 4π and its scaled FS
spectrum with ω0 = 0.5 rad. As the period is increased, the fundamental frequency is
decreased resulting in a denser spectrum. The ratio Xfs (k)/ω0 , in the limit, approaches
a finite limiting function. The period eventually approaches ∞ and the fundamental
frequency approaches zero. The result is that both the signal and its spectrum become
continuous and aperiodic. Figure 9.1e, f show the square pulse with period 8π and
its scaled FS spectrum with ω0 = 0.25 rad.
The limiting process can be thought of doubling and redoubling of the period T .
The order k of a specific frequency component gets doubled with the doubling of
the period. As the period is doubled, the frequency gets divided by 2. Therefore,
kω0 remains constant. The product TXfs (k) becomes a finite function X ( jω). For
example,
Xfs (1) = 0.3183 with ω0 = 1, Xfs (1)/1 = 1Xfs (1) = 0.3183 and kω0 = ω = 1.
Xfs (2) = 0.1592 with ω0 = 0.5, Xfs (2)/0.5 = 2Xfs (2) = 0.3183 and kω0 = ω = 1.
Xfs (4) = 0.0796 with ω0 = 0.25, Xfs (4)/0.25 = 4Xfs (4) = 0.3183 and kω0 = ω = 1.
9.1 The FT as a Limiting Case of the FS 251
(a) Period T= 2
(b) 0.5 =1
1 0
0.3183
X fs (k)
x(t)
0
0
- -0.5 0 -1 0 1
t k
(c) Period T= 4 (d) 0.5 = 0.5
1 0
0.3183
2X fs (k)
x(t)
0
0
-2 0 2 -2 0 2
t k
(e) Period T= 8
(f) 0.5 = 0.25
1 0
0.3183
4X fs (k)
x(t)
0
0
-4 0 4 -4 0 4
t k
Fig. 9.1 a A periodic square pulse with period 2π and b its FS spectrum Xfs (k) with ω0 = 1 rad;
c the pulse with period 4π and d its scaled FS spectrum 2Xfs (k) with ω0 = 0.5 rad; e the pulse in a
with period 8π and f its scaled FS spectrum 4Xfs (k) with ω0 = 0.25 rad; The corresponding scaled
FT is shown in a solid line
Now, the same procedure to determine X (k) in DFT is used to determine X ( jω).
Multiplying both sides by e−jω0 t and integrating over the infinite time domain, we
get
∞ ∞ ∞
1
x(t)e−jω0 t dt = X ( jω)ej(ω−ω0 )t d ω dt
−∞ −∞ 2π −∞
∞ ∞
1
= X ( jω)d ω ej(ω−ω0 )t dt
2π −∞ −∞
∞ j(ω−ω0 )t
1 e ∞
= X ( jω)d ω
2π −∞ j(ω − ω0 ) −∞
Now, as sinc function degenerates into an impulse with strength 2π, irrespective of
the value T , in the limit,
ej(ω−ω0 )t T 2 sin((ω − ω0 )T )
lim = lim = 2πδ(ω − ω0 )
T →∞ j(ω − ω0 ) −T T →∞ (ω − ω0 )
Since t or ω is zero, the values X ( j0) and x(0) can be determined easily. They can
be used to check the correctness of the derived closed-form expressions for X ( jω)
or x(t). ∞ ∞
1
X ( j0) = x(t)dt and x(0) = X ( jω)d ω,
−∞ 2π −∞
The FT and the IFT definitions can be expressed in terms of the the cyclic frequency
f . Since ω = 2πf and d ω = 2πdf , we get
∞ ∞
X ( j2πf ) = x(t)e−j2πft dt and x(t) = X ( j2πf )ej2πft df
−∞ −∞
Gibbs phenomenon can occur in either or both the time domain and frequency
domain.
The sufficient conditions, called the Dirichlet conditions, for the existence of the FT
are as follows. The first condition is that the signal x(t) is absolutely integrable. From
the definition of the FT, we get
∞ ∞ ∞
|X ( jω)| ≤ |x(t)e−jωt | dt = |x(t)||e−jωt | dt = |x(t)| dt,
−∞ −∞ −∞
since |e−jωt | = 1. The second condition is that x(t) may have only a finite number of
finite maxima and minima in any finite interval. The third condition is that x(t) may
have only a finite number of finite discontinuities of x(t) in any finite interval. All
physical signals have FT representation.
As Fourier representation of a signal is equivalent with respect to the least squares
error criterion, ∞ ∞
1
|x(t)|2 dt = |X ( jω)|2 d ω
−∞ 2π −∞
∞
That is, a square integrable signal, −∞ |x(t)|2 dt < ∞, has a FT representation. A
signal with finite energy satisfies the existence conditions.
Example 9.1 Find the IFT, x(t), of the spectrum X ( jω) = π(u(ω + ω0 ) − u(ω −
ω0 )), where u(ω) is the unit-step function.
Solution
ω0 ω0
1 sin(ω0 t)
x(t) = πejωt d ω = cos(ωt)d ω =
2π −ω0 0 t
254 9 The Fourier Transform
(a) (b)
0.2
X(j )
x(t)
0
0
-30 -20 -10 0 10 20 30 - 0.2
t
sin(0.2t)
Fig. 9.2 a t and b its FT spectrum, π(u(ω + 0.2) − u(ω − 0.2))
sin(ω0 t)
↔ π(u(ω + ω0 ) − u(ω − ω0 ))
t
Signal x(t) and its FT are shown, respectively, in Fig. 9.2a, b with ω0 = 0.2.
as limθ→0 sin(θ) = θ. The oscillations of the sine function are damped by the denom-
inator t. The period of the sine function is 2π/a.
The area enclosed by the sinc function is constant, irrespective of the value of a.
Finding the FT of x(t) in Example 9.1 with ω = 0,
∞
sin(0.2t)
X ( j0) = dt = π
−∞ t
It is also known that the area enclosed by the function is equal to the area of the
triangle inscribed within its main hump. The sinc function is only square integrable.
As a → 0, the function sin(at)
t
is expanded and, eventually, degenerates into a DC
function. The first pair of zeros at ω = ± πa move to infinity and the function becomes
a horizontal line with amplitude a. As a becomes larger, the numerator sine function
sin(at) of sin(at)
t
alone is compressed (frequency of oscillations is increased). As a
consequence, the amplitudes of all the ripples along with that of the main hump
increase with fixed ratios to one another. While the ripples and the main hump
become taller and narrower, the area enclosed by each and the total area enclosed
by the function remains fixed. In the limit, as a → ∞, the main hump and all the
ripples of significant amplitude are concentrated at t = 0 and sin(at)
t
degenerates into
an impulse with strength π.
9.1 The FT as a Limiting Case of the FS 255
Let xp (t) be a periodic signal of period T . Let us define an aperiodic signal x(t) that
is identical with xp (t) over its one period from t1 to t1 + T and is zero otherwise,
where t1 is arbitrary. The FT of this signal is
∞ t1 +T
−jωt
X ( jω) = x(t)e dt = xp (t)e−jωt dt
−∞ t1
1 1
Xfs (k) = X ( jω)|ω=kω0 = X ( jkω0 )
T T
The discrete samples of T1 X ( jω), at intervals of ω0 , constitute the FS spectrum for the
periodic signal xp (t). While the spectral values at discrete frequencies are adequate to
reconstruct one period of the periodic waveform using the inverse FS, spectral values
at continuum of frequencies are required to reconstruct one period of the periodic
waveform and the infinite extent zero values of the aperiodic waveform using the
IFT. A similar relationship exists between the DTFT and the DFT.
Example 9.2 Find the FS spectrum for the periodic signal xp (t), one period of which
is defined as
Solution
The derivative of the corresponding aperiodic pulse is composed of two shifted
impulses, δ(t + π2 ) and −δ(t − π2 ). The integral of the derivative is the square pulse.
Therefore, we find the FT of the impulses and, using the derivative and integral
properties of the FT, we find the FT. The FT of δ(t) is 1 and that of δ(t − T0 ) is e−jT0 ω
(using the FT shift property). It is relatively easier to find the FT using this method
for this type of signals. This method is called the derivative method of obtaining the
FT of x(t).
Let X ( jω) be the FT of x(t). The derivative of X ( jω) is jωX ( jω). Then, for the
example,
sin π2 ω
π π
j π2 ω −j π2 ω ej 2 ω − e−j 2 ω
jωX ( jω) = e −e and X ( jω) = =2
jω ω
256 9 The Fourier Transform
The waveform is even-symmetric and, therefore, the coefficients of all the sine
components are zero. From another point of view, since the complex coefficients
are real, the waveform is composed of cosine components only. Further, subtracting
the DC bias, the first-half and second-half of x(t) are antisymmetric. This is called
the odd half-wave symmetry. This implies that all the even-indexed, except the DC,
components are absent. The Fourier series for the square pulse is
1 2 1 1
x(t) = + cos(t) − cos(3t) + cos(5t) − · · · , (9.7)
2 π 3 5
as given in Chap. 7.
Example 9.3 Find the FT of the unit impulse signal x(t) = δ(t).
Solution
Using the sampling property of the impulse, we get
∞ ∞
X ( jω) = δ(t)e−jωt dt = e−jω0 δ(t)dt = 1 and δ(t) ↔ 1
−∞ −∞
The unit impulse signal is composed of complex sinusoids, with zero phase shift, of
all frequencies from ω = −∞ to ω = ∞ in equal proportion. That is,
∞ ∞ ∞
1 1 1
δ(t) = e dω = jωt
cos(ωt)d ω = cos(ωt)d ω
2π −∞ 2π −∞ π 0
Solution
∞
∞ ∞
e−(a+jω)t 1
X ( jω) = e−at e−jωt dt = e−(a+jω)t dt = − =
0 0 a + jω 0 a + jω
1
e−at u(t), a > 0 ↔
a + jω
∞ ∞ ∞
1 1 1 a j ω
x(0) = dω = dω − dω
2π −∞ a + jω 2π −∞ ω 2 + a2 2π −∞ ω 2 + a2
As the imaginary part of X ( jω) is odd, its integral evaluates to zero. Therefore,
ω ∞
1 ∞
a 1 ∞ d ωa 1 1
x(0) = dω = ω 2 = tan−1 =
2π −∞ ω 2 + a2 2π −∞ +1 2π a −∞ 2
a
1 for t > 0
sgn(t) =
−1 for t < 0
Solution
The sgn function, sgn(t), is the limit of a linear combination of two decaying expo-
nential signals. That is,
(a) (b)
0.5
1
real
0.25
X(j )
x(t)
e -2t u(t)
0
imaginary
0 -0.25
0 1 -2 0 2
t
Consequently,
1 1 2
X ( jω) = lim − =
a→0 a + jω a − jω jω
1
u(t) = 0.5 + 0.5sgn(t) ↔ πδ(ω) +
jω
That is, the spectrum of the complex sinusoid ejω0 t is an impulse at ω = ω0 with
strength 2π.
It follows that
9.2.1 Linearity
where a and b are arbitrary constants. As the integral defining the FT is a linear
operation, the FT is also a linear operation. Consider the FT pairs
9.2.2 Duality
The definitions of FT and IFT are almost identical in form. The three differences
between the definitions are the change of the signs of the exponents of the complex
exponentials, the interchange of the variables t and ω, and the constant appearing in
the definition of the IFT. Therefore, x(t) and X ( jω) are each other’s transform, with
some minor changes. That is, the variables t and ω can be interchanged with some
modifications.
The IFT is defined as
∞
1
x(t) = X ( jω)ejωt d ω
2π −∞
That is,
2πx(−t) ↔ X ( jω)
This is a forward transform with 2πx(−t) being the FT of X ( jω). That is, we get
2πx(−t) by taking the FT of x(t) twice in succession, 2πx(−t) = FT(FT(x(t))).
For an even x(t), as X ( jω) is also even, the sign change of either t or ω may be
omitted. If the FT and IFT definitions using the cyclic frequency f are used, the 2π
factor gets eliminated leaving only the sign change.
For example, consider the FT pair
1
e−at u(t), a > 0 ↔
a + jω
260 9 The Fourier Transform
1
2πeaω u(−ω), a > 0 ↔
a + jt
9.2.3 Symmetry
Let x(t) be real and even. Since x(t) cos(ωt) is even and x(t) sin(ωt) is odd, the
second term in the integrand in Eq. (9.8) contributes the value zero to the value of
this integral and we get
∞ ∞
1
X ( jω) = 2 x(t) cos(ωt)dt and x(t) = X ( jω) cos(ωt)d ω
0 π 0
If a signal x(t) is real and even, then its spectrum is also real and even. The FT 1 of
δ(t) is an example of the FT of an even function.
Let x(t) be real and odd. Since x(t) sin(ωt) is even and x(t) cos(ωt) is odd, the
first term in the integrand in Eq. (9.8) contributes the value zero to the value of this
integral and we get
∞ ∞
j
X ( jω) = −j2 x(t) sin(ωt)dt and x(t) = X ( jω) sin(ωt)d ω
0 π 0
If a signal x(t) is real and odd, then its spectrum is imaginary and odd.
1 for t > 0 2
↔
−1 for t < 0 jω
An arbitrary real signal x(t) can be decomposed into even and odd components,
x(t) = xe (t) + xo (t), as presented in Chap. 1. Therefore, the FT of x(t), which is
neither even nor odd, is X ( jω) = Xe ( jω) + Xo ( jω). If a signal x(t) is real, then the
real part of its spectrum X ( jω) is even and the imaginary part is odd, called the
conjugate symmetry. That is, X (−jω) = X ∗ ( jω). An example is
The shifting of a time-domain signal merely adds phase angles to its constituent
sinusoidal components, which are linearly proportional to their frequencies. If we
replace e±jωt0 X ( jω) in the IFT definition and combine the exponentials, we get
sin(aω)
u(t + a) − u(t − a) ↔ 2
ω
Using the theorem,
sin(aω) −jbω
u(t + a − b) − u(t − a − b) ↔ 2 e
ω
Let x(t) is replaced by x(t)e±jω0 t in the FT definition. Then, the two exponentials in
the resulting integrand can be combined to get
x(t)e±jω0 t ↔ X ( j(ω ∓ ω0 ))
The duality properties hold to both transform pairs and properties. The time-shifting
property is the dual of the frequency-shifting property.
Consider the FT pair
1
e−3t u(t) ↔
3 + jω
262 9 The Fourier Transform
Then,
(ej2t − e−j2t )
e−3t sin(2t)u(t) = e−3t u(t)
j2
1 1 1 2
↔ − =
j2 3 + j(ω − 2) 3 + j(ω + 2) (3 + jω)2 + 4
1
e−3t ej2t u(t) ↔
3 + j(ω − 2)
1 1 1 1
|ω=0 = and |ω=2 =
3 + jω 3 3 + j(ω − 2) 3
That is, the convolution operation in the time domain corresponds to much simpler
multiplication operation in the frequency domain. This result, due to the represen-
tation of the signals in terms of complex exponentials, is a major reason for the
dominant role of the frequency-domain analysis in the study of signals and systems.
Consider the convolution of x(t) = e−4t u(t) and h(t) = e−2t u(t). In the time
domain, we get
t t
−2τ −4(t−τ ) −4t
y(t) = x(t) ∗ h(t) = e e dτ = e e2τ d τ = 0.5(e−2t − e−4t )u(t)
0 0
9.2 Properties of the Fourier Transform 263
In the frequency domain, the convolution output is the product of their individual
FT. That is,
1 1 0.5 0.5
Y ( jω) = = −
2 + jω 4 + jω 2 + jω 4 + jω
The problem is to find the FT Z( jω) of the product z(t) = x(t)y(t) of two signals
x(t) and y(t) in the time domain, in terms of their individual FT. This is the dual of
the time-domain convolution property.
∞
z(t) = x(t)y(t) ↔ Z( jω) = x(t)y(t)e−jωt dt
−∞
∞
1 1
= X ( jv)Y ( j(ω − v))d v = X ( jω) ∗ Y ( jω)
2π −∞ 2π
The FT of
1 1 1
=
2 + jt 2 + jt (2 + jt)2
1
is the convolution of the FT of 2+jt
with itself divided by 2π. That is,
−ω
Z( jω) = (2π)e2ω u(−ω) ∗ e2ω u(−ω) = (2π) e2τ e2(ω−τ ) d τ
0
−ω
= (2π)e 2ω
d τ = −(2π)ωe u(−ω)
2ω
0
9.2.8 Conjugation
Let x(t) ↔ X ( jω). Then, x∗ (±t) ↔ X ∗ (∓jω). If we conjugate both sides of the FT
and IFT definitions, we get
∞ ∞
∗ ∗ ∗ 1
X ( jω) = x (t)e dt,
jωt
x (t) = X ∗ ( jω)e−jωt d ω
−∞ 2π −∞
For example,
1
e−t u(t) ↔
1 + jω
1
e−t u(t) ↔
1 − jω
1
e−t u(t) ↔
1 + jω
9.2.9 Cross-Correlation
Let x(t) = cos(t) and y(t) = sin(t). The approach is to find the correlation of x(t)
and y(t) using the FS first.
Then, the correlation of x(t) and y(t) in the frequency domain is the multiplication
of their FS with the second FS conjugated and the period 2π. The result is
9.2 Properties of the Fourier Transform 265
9.2.10 Time-Reversal
The frequency of the signal is increased and its period is decreased. The signal is
compressed and its spectrum gets expanded. Replacing t by 0.5t, we get
The frequency of the signal is decreased and its period is increased. The signal is
expanded and its spectrum gets compressed. If the scaling factor is negative, both
the signal and its spectrum get reversed.
Let x(t) ↔ X ( jω). By replacing at by τ , t by τa and dt by daτ , with a > 0, in the
FT definition of x(at), we get
∞
1 ∞
τ 1 ω
x(at)e−jωt dt = x(τ )e−jω a d τ = X j
−∞ a −∞ a a
1 ω
x(at) ↔ X j , a = 0
|a| a
1
The signal energy is changed by the scaling operation. The factor |a| scales the energy
suitably.
Consider the transform pair
sin(ω)
u(t + 1) − u(t − 1) ↔ 2
ω
Let a = 0.5. Using the property, the transform of
sin(2ω)
u(t + 2) − u(t − 2) ↔ 2
ω
Figure 9.4a, c show pulses with width 2 and its expanded version by a factor of 2,
respectively. Figure 9.4b, d show the respective FT spectra.
9.2 Properties of the Fourier Transform 267
(a) (b)
1 2
X(j )
x(t)
0
0
-2 -1 0 1 2 -12 -8 -4 0 4 8 12
t
(c) (d)
1 4
X(j )
x(t)
0
0
-4 -2 0 2 4 -12 -8 -4 0 4 8 12
t
Fig. 9.4 a A pulse with width 2; b its spectrum; c a pulse with width 4; d its spectrum
d (cos(ω0 t))
= −ω0 sin(ω0 t) ↔ ( jω0 )(π(−δ(ω + ω0 ) + δ(ω − ω0 ))
dt
= −jω0 π(δ(ω + ω0 ) − δ(ω − ω0 ))
268 9 The Fourier Transform
Convolution is the integral of product of two signals, with one of them time reversed.
Consider the time-reversed and shifted version u(t − τ ) of the unit-step signal u(τ ).
If we multiply a signal by u(t − τ ), the product is the same signal from −∞ to t and
the rest from t to ∞ zero. Therefore, the integral of the product is the integral of the
signal from −∞ to t.
The definite integral, y(t), of a time-domain signal, x(t), can be expressed as the
convolution of x(t) and the unit-step signal, u(t), as
t ∞
y(t) = x(τ )d τ = x(τ )u(t − τ )d τ = x(t) ∗ u(t)
−∞ −∞
Using the time-domain convolution theorem, with x(t) ↔ X ( jω), and u(t) ↔ 1
jω
+
πδ(ω), we get
t
1 X ( jω)
x(τ )d τ ↔ X ( jω) + πδ(ω) = + πX ( j0)δ(ω)
−∞ jω jω
−jω
t
X ( jω) e −1
y(t) = x(τ )d τ ↔ Y ( jω) = + πδ(ω) = πδ(ω) +
−∞ jω ω2
(a) 1 (b) 1
x(t)
y(t)
0 0
-1 0 1 2 -1 0 1 2
t t
To appreciate the use of theorems, let us do this example using the FT definition.
Assume that we have obtained y(t) in the time domain. First, we have to split the
function y(t) into the ramp section and the delayed unit-step signal. This is the use
of linearity theorem.
The FT of the delayed unit-step signal is
e−jω
πδ(ω) +
jω
Combining the two partial FT, we get the same FT as that obtained using the theo-
rem. Properties are so convenient for theoretical analysis. Of course, the numerical
approximation of the Fourier spectrum with the DFT along with fast algorithms
makes Fourier analysis an indispensable tool in the applications of science and engi-
neering.
As an another example,
1 sin(ω0 t)
−jπ (−δ(ω + ω0 ) + δ(ω − ω0 )) =
ω0 ω0
9.2.14 Frequency-Differentiation
dX ( jω) dX ( jω)
(−jt)x(t) ↔ or tx(t) ↔ j
dω dω
For the nth derivative, we get,
d n X ( jω) n d X ( jω)
n
(−jt)n x(t) ↔ or (t) n
x(t) ↔ ( j)
d ωn d ωn
270 9 The Fourier Transform
For example,
1 1
e−3t u(t) ↔ and te−3t u(t) ↔
jω + 3 ( jω + 3)2
Orthogonal transforms have the energy preservation property. That is, the energy of
a signal can be derived either from its time-domain or frequency-domain represen-
tations. The energy of a signal is its autocorrelation with lag zero. That is,
∞ ∞
∗ 1
x(t)x (t)dt = X ( jω)X ∗ ( jω)d ω
−∞ 2π −∞
∞ ∞
1
E= |x(t)|2 dt = |X ( jω)|2 d ω
−∞ 2π −∞
This equivalent energy representation is called the Parseval’s theorem. For real sig-
nals, the autocorrelation is even and we get
∞ ∞
1
E= |x(t)| dt = 2
|X ( jω)|2 d ω
−∞ π 0
The quantity |X ( jω)|2 is called the energy spectral density of the signal, since
1
2π
|X ( jω)|2 d ω is the signal energy over the infinitesimal frequency band ω to
ω + d ω.
Example 9.8 Find the energy of the signal x(t) = e2t u(−t). Find the value of T such
that 95% of the signal energy lies in the range 0 ≤ t ≤ T . What is the corresponding
signal bandwidth B, where B is such that 95% of the spectral energy lies in the range
0 ≤ ω ≤ B.
Solution
1
e2t u(−t) ↔
2 − jω
Solving for T , we get T = 0.7489 s. This value is useful in truncating the signal for
numerical analysis.
From the spectrum,
1 B dω 1 −1 B = 0.2375 or B = 2 tan(0.2375(2π)) = 25.4124 rad/s
= tan
π 0 22 + ω 2 2π 2
The sampling interval required to sample this signal can be determined using this
value. The sampling frequency must be greater than (2)(25.4124) rad/s. Therefore,
2π
the sampling interval must be smaller than (2)(25.4124) = 0.1236 s. For practical sig-
nals, this type of analysis can be carried out using numerical methods.
The input and output of a LTI system, in the frequency domain, is related by
the transfer function H ( jω) as Y ( jω) = H ( jω)X ( jω), where X ( jω), Y ( jω), and
H ( jω) are the FT of the input, output, and impulse response of the system. An ideal
filter will pass the amplitude of the frequency components of a deterministic signal,
unattenuated, which lie in its passband.
The output energy spectrum is given by
The quantity |H ( jω)|2 is called the energy transfer function, as it relates the input
and output energy spectral densities of a system. An ideal filter will pass the average
power of the frequency components of a random signal, unattenuated, which lie in
its passband.
Fourier transform version of the Fourier analysis is its most general version. It is
capable of representing all types of signals. Therefore, it is the only version that can
be used for the analysis of mixed class of signals. In both the time and frequency
domains, the FT is continuous and aperiodic. Using scaled and shifted continuous
impulses, the FT represents other classes of signals. If its spectrum is sampled, then
we get a periodic version of the time-domain signal corresponding to the FS represen-
tation of signals. If the time-domain signal is sampled, then we get a periodic version
272 9 The Fourier Transform
−j
(δ(k − 1) − δ(k + 1)), ω0 = 2
2
Multiplying this result by 2π and replacing the discrete impulses by the corresponding
continuous impulses, we get the FT pair
In general,
cos(ω0 t + θ) ↔ π(e−jθ δ(ω + ω0 ) + ejθ δ(ω − ω0 ))
9.3 Fourier Transform of Mixed Class of Signals 273
(a) (b)
0.5 FS FT
X fs (k)/j
X(j )/j
0 0
-0.5 -
-2 0 2 -2 0 2
Fig. 9.6 a The FS spectrum, Xfs (k), of sin(2t); b the FT, X ( jω), of sin(2t)
The FS and FT spectra of sin(2t) are shown in Fig. 9.6a, b, respectively. Finding the
IFT, we get
∞
1 1 j2t
x(t) = (−jπ) (δ(ω − 2) − δ(ω + 2))ejωt d ω = (e − e−j2t ) = sin(2t)
2π −∞ j2
The spectra in Fig. 9.6a, b are equivalent representations of the same waveform
sin(2t) by the FS and the FT.
While most naturally occurring signals are continuous, as digital processing is advan-
tageous, the signal has be digitized invariably. The sampling interval is an important
parameter in this process. In this section, we study the relation between the sampling
interval and the aliasing effect. In the last section, we sampled the FT spectrum to
determine the FT of a periodic signal. Now, we are going to sample the time-domain
waveform to study the characteristics of the resulting periodic spectrum. The period
of this spectrum is ωs = 2π/Ts , where Ts is the sampling interval in the time domain.
Two completely equivalent expressions for the spectrum of a sampled signal are
derived. Once we represent a continuous signal by samples at discrete intervals, the
effective frequency range is reduced from infinity to a finite value and its spectrum
becomes periodic. A periodic signal has a FS representation. That is, the periodic
spectrum has a time-domain representation composed of discrete samples. This is
the same as DTFT representation with the time-domain and frequency-domain roles
interchanged in the FS representation. The resulting expression for the spectrum of
a sampled signal is useful for computational purposes. In a later section, we take the
samples of a continuous signal and approximate its spectrum using the DFT.
The other point of view of a sampled signal is to consider it is as a sequence of
continuous impulses. The continuous signal is multiplied by a sampling train to get
the sequence of continuous impulses. Multiplication in the time domain becomes
274 9 The Fourier Transform
convolution of their spectra in the frequency domain. The FT of the impulse train
is also an impulse train in the frequency domain. Convolution of a signal with an
impulse is relocating it at the location of the impulse. Therefore, using this approach,
the spectrum of the sampled signal is represented as a periodic repetition of that
of the continuous signal being sampled. This representation enables us to visualize
the spectrum from a knowledge of that of the continuous signal. Further, it clearly
demonstrates the aliasing effect. It helps to truncate the bandwidth of an infinite
extent spectrum to a finite extent so that a sufficiently short sampling interval can be
selected to sample a continuous signal.
A continuous periodic unit-impulse train is given by
∞
s(t) = δ(t − nTs ),
n=−∞
where Ts is the period and n is an integer. The FS representation of the impulse train,
from Chap. 7, is given as
∞
1 jkωs t 2π
s(t) = e , ωs =
Ts Ts
k=−∞
The sampled signal xs (t), which is the product of x(t) and s(t), is also given by, using
the FS representation of the impulse train,
∞
1 1
xs (t) = x(t)ejkωs t = (· · · + x(t)e−jωs t + x(t) + x(t)ejωs t + · · · )
Ts Ts
k=−∞
Let xs (t) ↔ Xs ( jω). Then, from the linearity and frequency-shift properties of the
FT, we get
1
Xs ( jω) = (· · · + X ( j(ω + ωs )) + X ( jω) + X ( j(ω − ωs )) + · · · )
Ts
∞
1
= X ( j(ω − kωs )) (9.10)
Ts
k=−∞
Equation (9.10) expresses the FT spectrum of the sampled signal Xs ( jω) as a scaled
periodic repetition of X ( jω). The factor T1s arises from the fact that
9.3 Fourier Transform of Mixed Class of Signals 275
∞ ∞
x(t) = x(τ )δ(t − τ )d τ = lim x(nTs )Ts δ(t − nTs ) = lim Ts xs (t)
−∞ Ts →0 Ts →0
n=−∞
The spectrum becomes periodic, since sampling reduces the infinite frequency range
to a finite one. The longer is the sampling interval, the shorter is the unique frequency
range available for the representation of the signal.
This form of representation of the FT spectrum of a sampled signal makes it easy
to visualize the spectrum from a knowledge of X ( jω). If the spectrum X ( jω) is
band-limited and the period of Xs ( jω) is longer than the bandwidth of X ( jω), then
there will be no overlap between the copies of X ( jω) in Xs ( jω). If this condition is
fulfilled, by lowpass filtering, we can recover X ( jω) from Xs ( jω) and x(t) can be
reconstructed exactly from its samples. This is the ideal situation. In practice, X ( jω)
usually has a long tail so that there will be some overlap between the copies of X ( jω)
in Xs ( jω), resulting in aliasing in the frequency domain. It has to be ensured that the
sampling interval in the time domain is sufficiently short to keep the distortion of
the reconstructed signal, due to aliasing, negligible. If the spectrum is sampled, then
aliasing occurs in the time domain.
Figure 9.7a, b show, respectively, the continuous sinc function and its aperiodic
FT spectrum.
sin π2 t π π
x(t) = ↔ X ( jω) = u ω + −u ω−
πt 2 2
The signal is continuous and its spectrum is aperiodic, with value 1 between ω = − π2
to ω = π2 . The peak value of the sinc function is 0.5.
Figure 9.7c, d show the sampled sinc function, with Ts = 0.5, and its periodic FT
2π
spectrum with period 0.5 = 4π rad and amplitude 0.5 1
= 2.
∞
sin π2 (0.5n)
xs (t) = δ(t − 0.5n) ↔
n=−∞
π(0.5n)
∞
π π
Xs ( jω) = 2 u ω + − 4kπ − u ω − − 4kπ
2 2
k=−∞
At any discontinuity of the time-domain function, the strength of the sample should
be equal to the average value of the right- and left-hand limits.
The sampled signal is a sum of impulses and
(a) (b)
(c) (d)
(e) (f)
(g) (h)
(i) (j)
sin( π t )
Fig. 9.7 a The sinc function πt2 and b its FT spectrum; c samples of a with Ts = 0.5 s and d
its periodic FT spectrum; e discrete samples of a with Ts = 0.5 s and f its DTFT spectrum with
period 4π rad, which is the same as in d; g the same samples as in e with Ts = 1 and h its DTFT
spectrum with period 2π rad; i samples of a with Ts = 2 s and j its periodic DTFT spectrum with
period π radians
This form for Xs ( jω) implies that it is similar to the FS with the roles of the time
and frequency domains interchanged and corresponds to the DTFT. The time-domain
samples x(nTs ) are the FS coefficients of the corresponding continuous periodic spec-
trum Xs ( jω). Equation (9.11) is, of course, completely equivalent to that in Eq. (9.10)
and they express the FT of a sampled signal in different forms.
9.3 Fourier Transform of Mixed Class of Signals 277
Let x(nTs ) be the discrete sequence constructed from the sampled signal x(nTs )δ(t −
nTs ) with the amplitude of x(nTs ) being the same as the strength of the corresponding
continuous impulse. The DTFT of x(nTs ) is defined as
∞
X (ejωTs ) = x(nTs )e−jnωTs (9.12)
n=−∞
The expressions in Eqs. (9.10) and (9.11), defining the FT of the sampled signal
and the DTFT, Eq. (9.12), of the corresponding discrete sequence yield the same
spectrum. Figure 9.7e, f show, respectively, the discrete samples of the sinc function
x(0.5n) = (π(0.5n)
sin π2 (0.5n))
with Ts = 0.5 s and its DTFT spectrum with period 4π rad,
which is the same as in (d).
As scaling the frequency axis is easier than computing the DTFT with the sampling
interval in the defining equation, the DTFT is usually computed assuming that Ts =
1 s. Then, the frequency axis is rescaled. Figure 9.7g, h show, respectively, the samples
as in (e) with Ts = 1 s and its DTFT spectrum with period 2π rad. The FT of the
corresponding sampled continuous signal xs (t) is obtained by scaling the frequency
axis of this DTFT spectrum so that the period of the spectrum becomes 2π Ts
, as can
be seen from Figs 9.7g, h, c, and d.
If the sampling frequency is not greater than two times that of the frequency
of highest frequency component of the signal, we get a corrupted version of its FT
spectrum, as shown in Fig. 9.7i, j, since the periodic repetition of X ( jω) results in the
overlapping of its nonzero portions. Further, the sine component at half the sampling
frequency cannot be properly represented. With Ts = 2, except at t = 0, we get zero
sample values of the time-domain signal.
∞
sin π2 (2n)
x(nTs ) = ↔
n=−∞
π(2n)
∞
π π
X (ejωTs ) = 0.5 u ω + − kπ − u ω − − kπ
2 2
k=−∞
With continuous signals, both the time-domain form and its spectrum cannot be
periodic. Only in the case of the DFT, both the time- and frequency-domain forms
can be periodic with the signal expressed as a linear combination of discrete harmonic
components.
278 9 The Fourier Transform
Assuming that a periodic signal x(t) is band-limited, its FT from Eq. (9.9) is
N
N
x(t) = Xfs (k)e jkω0 t
↔ X ( jω) = 2π Xfs (k)δ(ω − kω0 ),
k=−N k=−N
where ω0 = 2π
T
, the fundamental frequency of x(t). The FT pair for the impulse train
is
∞
∞
2π
s(t) = δ(t − nTs ) ↔ S( jω) = δ(ω − mωs )
n=−∞
Ts m=−∞
As X (k) = (2N + 1)Xfs (k), where X (k) is the DFT of the 2N + 1 discrete samples
of x(t) over one period, we get
∞
xs (t) = x(nTs )δ(t − nTs ) ↔ Xs ( jω)
n=−∞
∞
N
2π
= X (k)δ(ω − kω0 − mωs )
(2N + 1)Ts m=−∞
k=−N
The period of the time-domain signal x(n) of the DFT is 2N + 1 samples and that
of corresponding sampled continuous signal xs (t) is (2N + 1)Ts = T s. The period
of the FT spectrum is ωs = 2πTs
rad and the spectral samples are placed at intervals of
ω0 = (2N +1)Ts = T rad.
2π 2π
(a) (b)
8
1 N=16 DFT
X(k)
x(n)
Period=16 samples
-1
0
0 5 10 15 0 5 10 15
n k
(c) (d)
2
1 T s =0.5 FT
0.5
X s(j )
x s(t)
0
-0.5
Period=4
-1
0
0 2 4 6 0 2 3
t seconds
Fig. 9.8 a The discrete samples of the continuous cosine wave cos( 2π
8 t) with sampling interval
Ts = 0.5 s and b its DFT spectrum; c the sampled version of the cosine wave cos( 2π
8 t) and d its
periodic FT spectrum
∞
2π
xs (t) = cos (0.5n) δ(t − 0.5n) ↔
n=−∞
8
∞
2π 2π 2π
Xs ( jω) = 8δ ω − − 4mπ + 8δ ω + − 4mπ
(16)(0.5) m=−∞ 8 8
Both the DFT and FT spectra are equivalent representations of the same waveform.
The 16-point DFT spectrum, with amplitude 8 at k = 1 and k = 15, indicates a cosine
waveform cos( 2π 16
n). Given that the sampling interval is 0.5 s, the corresponding
continuous waveform is cos( 2π 8
t).
The term 4mπ in the FT representation indicates that the spectrum is periodic
with period 4π rad and, hence, the sampling interval in the time domain is 0.5 s.
The strength 8/16 of the 2 impulses is Xfs (±1) = 0.5. The product (2π)(0.5) = π
indicates that the amplitude of the cosine waveform is 1 with frequency 2π 8
rad. The
value 0.5 in the denominator also indicates that the sampling interval is 0.5 s.
280 9 The Fourier Transform
where x(t), h(t), and y(t) are, respectively, the system input, impulse response, and
output, and X ( jω), H ( jω), and Y ( jω) are their respective transforms. The entity in
the frequency domain, H ( jω), is called the transfer function, since multiplying it
with the input yields the output. The transfer function is the transform of the impulse
response and the system representations in the respective domains are equivalent.
An impulse in the time domain has a uniform transform in the frequency domain,
with each frequency component having the same magnitude and zero phase. There-
fore, the output of a system in the frequency domain for an impulse input is called
its frequency response, in addition to transfer function.
9.4 Applications of the Fourier Transform 281
Example 9.10 Find the steady-state current i(t), using the FT, in the series circuit,
consisting of a resistance R and an inductance L, excited by the input voltage Eej(ωt+θ) .
Given that R = 10 , L = 0.01 H, E = 100, θ = π3 , and ω = 2π60 rad/s. Deduce the
steady-state current i(t), if the excitation is 3 cos(4π60t + π6 )
Solution
The circuit is governed by the differential equation
di(t)
L + Ri(t) = Eej(ωt+θ)
dt
In the frequency domain, we get
Eejθ
(R + jωL)I ( jω) = Eejθ and I ( jω) =
R + jωL
282 9 The Fourier Transform
E
ej(ωt+θ−tan ( R ))
−1 ωL
i(t) = √
R2 + ω 2 L2
Example 9.11 Find the impulse response, using the FT, of the system governed by
the differential equation
dy(t) dx(t)
+ 2y(t) = 4 + 3x(t)
dt dt
Solution
3 + 4jω 5
H ( jω) = =4−
2 + jω 2 + jω
The impulse response of the system, which is the IFT of H ( jω), is h(t) = 4δ(t) −
5e−2t u(t).
Example 9.12 Find the zero-state response of the system governed by the differential
equation
d 2 y(t) dy(t) d 2 x(t) dx(t)
+ 5 + 6y(t) = + + x(t)
dt 2 dt dt 2 dt
With X ( jω) = 1
1+jω
,
( jω)2 + ( jω) + 1
Y ( jω) = H ( jω)X ( jω) =
(( jω)2 + 5( jω) + 6)(1 + jω)
0.5 3 3.5
Y ( jω) = − +
1 + jω jω + 2 ( jω + 3)
9.4 Applications of the Fourier Transform 283
For all applications where Fourier analysis is suitable, it is preferred since it can be
implemented using fast algorithms. The generalized version of the Fourier analysis,
the Laplace transform, is suitable for stable and unstable system analysis and design
with or without initial conditions.
Filters are important components in signal and system analysis. The major types
of filters, such as lowpass or highpass, are presented using ideal filter models. As
always, in designing engineering devices, both the theoretical and practical aspects
must be considered. In essence, the ideal characteristics of devices designed using
the theory can be achieved only with acceptable limitations in practice. We consider
the limitations in the realization of practical filters.
The ideal frequency response of a lowpass filter is shown in Fig. 9.9. As the
response is even-symmetric, the specification of the response over the interval from
ω = 0 to ω = ∞, shown in thick lines, characterizes a filter.
1 for 0 ≤ ω < ωc
|H ( jω)| =
0 for ω > ωc
Pass
band Stopband
|H(jω)|
1 Lowpass
−ωc 0 ωc ω
The impulse response of physically realizable systems must be causal. The even
and odd components, for t > 0, of a causal time function x(t) are given as
The FT of an even real signal is real and even and that of an odd signal is imaginary
and odd. Therefore, x(t) can be obtained by finding the inverse FT of either the real
part or the imaginary part of its spectrum X ( jω). That is,
∞ ∞
2 2
x(t) = Re(X ( jω)) cos(ωt)d ω = − Im(X ( jω)) sin(ωt)d ω, t > 0
π 0 π 0
1
u(t) = 0.5 + 0.5sgn(t) ↔ πδ(ω) +
jω
Now,
u(t) = 2ue (t) = 2u0 (t), t > 0 and ue (t) = −u0 (t), t < 0
The point is that the real and imaginary parts or, equivalently, the magnitude and the
phase of the FT of a causal signal are related. This implies that there are constraints,
for the realizability, on the magnitude of the frequency response, H ( jω), of a practical
filter. These constraints are given by the Paley–Wiener criterion as
∞
| loge |H ( jω)||
dω < ∞
−∞ 1 + ω2
To satisfy this criterion, the magnitude of the frequency response |H ( jω)| can be
zero at discrete points but not over any continuous band of frequencies. If H ( jω) is
zero over a band of frequencies, | loge |H ( jω)|| = ∞ and the condition is violated.
However, despite zeros of H ( jω) at a finite set of discrete frequencies, the value of the
integral may still be finite, although the integrand is infinite at these frequencies. In
addition, any transition of this function cannot vary more rapidly than by exponential
order. Obviously, the frequency response of the ideal filters fails to meet the Paley–
Wiener criterion. Further, an infinite order filter is required to have a flat passband.
Therefore, neither the flatness of the bands nor the sharpness of the transition between
the bands of ideal filters is realizable by practical filters.
9.5 Approximation of the Fourier Transform 285
As the FT is continuous and aperiodic in both the domains and the DFT is discrete
and periodic, both the sampling interval and record length have to be fixed in approx-
imating the samples of the FT by the DFT. The criteria in selecting these parameters
are that both the reconstructed signal and its spectrum must be adequate represen-
tations of the signal. The defining integrals of the FT and the IFT are approximated
using the rectangular rule of numerical integration. As periodicity is assumed in DFT
and IDFT computation, the sampling can start at t = 0 or ω = 0. The given truncated
signal or spectrum, whatever range it is defined, can be periodically extended for this
purpose.
The problem of numerical integration is the numerical evaluation of a definite
integral. That is, to find the area under the given function between the given limits.
Using the rectangular rule of integration, we divide the period T into N intervals of
width Ts = NT and represent the signal at N points as
T T T
x(0), x ,x 2 , . . . , x (N − 1)
N N N
Then, the total area is the sum of those of the N rectangles. The sampling interval in
the time domain is Ts s and that in the frequency domain is NT 2π
s
= 2π
T
rad/s.
The FT definition is approximated as
N −1
2πk
x(nTs )e−j N nk , k = 0, 1, . . . , N − 1
2π
X j = Ts (9.13)
NTs n=0
N −1
1 2πk j 2π nk
x(nTs ) = X j e N , n = 0, 1, . . . , N − 1 (9.14)
NTs NTs
k=0
The approximate samples of the FT spectrum are obtained by multiplying the DFT
coefficients of the samples of the input signal by the sampling interval Ts . By dividing
the IDFT values of the samples of the input FT spectrum by Ts , we get the approximate
samples of the time-domain signal.
Example 9.13 Find the approximate samples of the FT magnitude spectrum of the
signal x(t) = e−2t u(t) using the DFT.
Solution
1 1 1
X ( jω) = and |X ( jω)| = √ ≈ for ω >> 2
2 + jω 4 + ω2 ω
286 9 The Fourier Transform
(a) 1
(b)
-2t
e u(t) 0.6
T =4
N =4 0.5
|X(j )|
x(t)
0.5
0 0
0 1 2 3 0 1 2 3
- 2 - 2 - 2
t 4 4 4
x(t)
0.5
0 0
0 6 50 100 0 1 2 3
t
Fig. 9.10 a The exponential waveform x(t) = e−2t u(t), with 4 samples over the range 0 ≤ t < 4;
b the magnitude of the FT (solid line) and the samples of the FT obtained through the DFT with
N = 4 (dots) and N = 1024 (crosses) samples; c the magnitude of the FT obtained through the
DFT with N = 1024 samples; d the partially and fully reconstructed waveform
Figure 9.10a shows the exponential signal e−2t u(t) with 4 samples over a record
length of T = 4 s. The record length has to be sufficiently long so that the amplitude
or power of the signal becomes negligible beyond the record length chosen. With
T = 4, e−8 = 0.00033546, which is very small compared with the peak value of the
signal 1. Figure 9.10b shows the magnitude of the FT and the samples of the FT
obtained through the DFT with N = 4 and N = 1024 samples. The 4 sample values
of the signal in Fig. 9.10a are
It should be remembered that the number of samples has to be quite large for adequate
representation. To make the calculation simple for illustration purpose, we use 4
samples. As the first sample value occurs at a discontinuity, it is assigned the average
of the left- and right-hand limits of the discontinuity. The bandwidth of the signal is
also infinite. As with typical practical signals, the spectral values become negligible
beyond some finite range. The magnitudes of the DFT of these values, after scaling
by Ts = 1 s, are
{0.6561, 0.4997, 0.3805, 0.4997}
9.5 Approximation of the Fourier Transform 287
For example, the DC coefficient 0.6561 is the sum of the input samples. As the
second half of the DFT spectrum is redundant, only the first three values are useful.
The magnitudes of the first 5 samples of the FT, X ( jω), are
With ω = 0, we get X ( jω) = 0.5. Since the sampling interval Ts = 1 s is too long,
due to aliasing, the spectral samples obtained by the DFT are very inaccurate. For
example, with N = 4 samples, the DC coefficient is aliased with every fourth spectral
sample. Adding all the aliased components, the spectral value becomes 0.6561. In
a similar manner, all the coefficients get aliased. The magnitudes of the first few of
the DFT values, with Ts = 0.5 s, are
The magnitudes of the first few of the DFT values, with Ts = 0.25 s, are
The aliasing gets reduced and the accuracy improves with more samples, as expected.
The magnitudes of the first five samples of the FT obtained through the DFT with
N = 1024 are
{0.4998, 0.3931, 0.2684, 0.1953, 0.1516}
The DFT values are quite close to the theoretical values. For an arbitrary wave-
form, with no FT expression available, one has to resort to trial and error method
in approximating the FT spectrum. In general, the DFT values will never be exactly
equal to the analytical values, but they can be made adequate, for practical purposes,
by selecting appropriate sampling interval and record length. If the number of spec-
tral samples are insufficient to represent the spectrum properly (picket-fence effect),
for a given record length, the signal may be zero padded to increase the number of
spectral samples.
A similar procedure for the approximation of the IFT is required. Now, we have
to fix the record length of the spectrum. The spectrum, as shown in Fig. 9.10c for
positive values of ω (the spectrum is conjugate-symmetric), is slowly decaying and
is of infinite extent. The cutoff frequency has to be selected to suit the accuracy
288 9 The Fourier Transform
requirements. The magnitude of the spectrum is approximately 1/ω for large values
of ω. The peak value of the spectrum is 0.5. If we want to discard the values of
the spectrum those are less than one-hundredth of the peak, then ω = 200 rad is the
cutoff frequency. Of course, the cutoff frequency can also be fixed based on signal
energy.
In contrast to most signals in the time domain, the spectra of signals are almost
always two-sided. For real signals, the spectrum is conjugate-symmetric and, usu-
ally, the positive frequency side is shown, as can be seen in Fig. 9.10b, c. For the
example waveform, the record length T in the time domain is 4 s and ωs , the sampling
frequency of the spectrum is π/2 rad.
Let the sampling interval of the reconstructed signal be Ts s. Then, the record
length of the reconstructed signal is NTs s, where N is the number of samples. Let
the number of samples N be 7 and the sampling interval Ts be 0.2 s. Then, the record
length T in the time domain is 1.4 s. Let the frequency increment be 2.5π. Then, the
4 samples of the FT spectrum at
are
{0.5, 0.0304 − j0.1196, 0.0080 − j0.0626, 0.0036 − j0.0421}
Conjugating the last 3 spectral samples and concatenating in the reverse order, we
get
are
{1, 0.6703, 0.4493, 0.3012, 0.2019, 0.1353, 0.0907}
doubling the frequency so that the spectral values at the middle of the spectrum
(around X (N /2)) become negligible for real signals. For complex signals, the spec-
tral values should become negligible at the end of the spectrum. That frequency is
appropriate for sampling the signal. Once the sampling frequency is fixed, we keep
increasing the record length and compute the DFT of the samples. When the DFT
values are almost the same for two consecutive record lengths, the record length is
fixed. Further, zero pad the signal sufficiently and compute the DFT so that the there
is no picket-fence effect.
9.6 Summary
• The FT is the most general version of the Fourier analysis. It can represent all types
of signals and, therefore, most useful in the analysis of mixed class of signals in
addition to the analysis of continuous aperiodic signals.
• The FT is primarily used in the analysis of continuous aperiodic signals. The
spectrum is also continuous and aperiodic.
• The FT can be considered as the limiting case of the FS with the period of the
waveform tending to infinity. The FT can also be considered as the limiting case
of the DTFT with the sampling interval of the time-domain sequence tending to
zero.
• The FT spectrum is a relative amplitude spectrum.
• The FT is defined by an infinite integral. Therefore, a sufficient condition for its
existence is that the time-domain signal is absolutely integrable.
• The FT can be effectively approximated by the DFT in practical applications.
Exercises
9.1 Find the FT of the rectangular pulse x(t) = u(t + 3) − u(t − 3) using the defining
integral. Find X ( j0) and X ( j0.5π).
* 9.2 Find the FT of the signal x(t) = e−2t cos(3t)u(t), a > 0 using the defining
integral. Find X ( j0) and X ( jπ).
9.3 Find the FT of the signal x(t) = e−2|t| using the defining integral. Find X ( j0)
and X ( j2).
9.4 Find the FT of the signal
* 9.5.1
x(t) = t, for 0 < t < 1
9.5.2
x(t) = sin(t), for 0 < t < π
9.6 Using the duality property, find the FT of the signal x(t).
9.6.1. x(t) = 2π(3+jt)
1
.
* 9.6.2. x(t) = 2π πδ(t) + jt1 .
1
9.6.3. x(t) = 4
π(16+t 2 )
.
9.7 Using the linearity and frequency-shifting properties, find the FT of x(t).
9.7.1 x(t) = 2 sin(3t) cos(3t).
9.7.2
x(t) = cos(3t) cos(2t) − sin(3t) sin(2t)
* 9.7.3
9.8 Find the convolution of x(t) and h(t) using their FT.
9.8.1
9.14.2
2π π
x(t) = cos t+ .
8 4
9.15 Find the FT of x(t). Find the FT of the sampled version xs (t) of x(t) in 2 different
forms with sampling interval Ts = 1 and Ts = 0.5 s. List the sample values of the 3
versions of the spectra at ω = {0, 0.25π, 0.5π, 0.75π, π} and compare the results.
* 9.15.1 x(t) = u(t + 5) − u(t − 5).
9.15.2 x(t) = (t + 1)u(t + 1) − 2tu(t) + (t − 1)u(t − 1).
9.16 Find the DFT of x(t) with sampling interval Ts = 0.5 s. Express the FT repre-
sentation of the sampled xs (t) in terms of the DFT coefficients.
9.16.1
2π
x(t) = 3 cos 2 t
8
9.16.2
2π
x(t) = sin t
8
292 9 The Fourier Transform
* 9.16.3
2π π
x(t) = 2 cos 3 t +
8 3
9.17 Find the steady-state current i(t), using the FT, in the series circuit, consisting
of a resistance R and an inductance L, excited by the input voltage Eej(ωt+θ) . Given
that R = 20 , L = 0.02 H, E = 100, θ = π6 , and ω = 2π60 rad/s.
9.18 Find the impulse response, using the FT, of the system governed by the differ-
ential equation
dy(t) dx(t)
+ y(t) = 2 + 3x(t)
dt dt
* 9.19 Find the zero-state response of the system governed by the differential equation
It is the availability of fast algorithms to compute the DFT that makes Fourier analysis
indispensable in practical applications, in addition to its theoretical importance from
its invention. In turn, the other versions of the Fourier analysis can be approximated
adequately by the DFT. Although the algorithm was invented by Gauss in 1805, it is
the widespread use of the digital systems that has given its importance in practical
applications. The algorithm is based on the classical divide-and-conquer strategy
of developing fast algorithms. A problem is divided into two smaller problems of
half the size. Each smaller problem is solved separately and the solution to the
original problem is found by appropriately combining the solutions of the smaller
problems. This process is continued recursively until the smaller problems reduce
to trivial cases. Therefore, the DFT is never computed using its definition. While
there are many variations of the algorithm, the order of computational complexity
of all of them is the same, O(N log2 N ) to compute a N -point DFT against O(N 2 )
from its definition. It is this reduction in computational complexity by an order that
has resulted in the widespread use of the Fourier analysis in practical applications
of science and engineering. In this chapter, a particular variation of the algorithm,
called the PM DFT algorithm, is presented. The algorithm is developed using the
half-wave symmetry of periodic waveforms. This approach gives a better physical
explanation of the algorithm than other approaches such as matrix factorization. The
DFT is defined for any length. However, the practically most useful DFT algorithms
are of length that is an integral power of 2. That is N = 2M , where M is a positive
integer. If necessary, zero padding can be employed to the sequences so that they
satisfy this constraint.
A physical understanding of the basics of the DFT algorithms can be obtained using
the half-wave symmetry of periodic waveforms. If a given periodic function x(n)
with period N satisfies the condition
N
x n± = x(n),
2
then it is said to be odd half-wave symmetric. The samples of the function over any
half period are the negatives of those in the succeeding or preceding half period. If
the DFT is computed over the period N , then the even-indexed DFT coefficients will
be zero. That is, the function is composed of odd-indexed frequency components
only. It is due to the fact that any periodic function can be uniquely decomposed
into even half-wave and odd half-wave symmetric components. If the even half-
wave symmetric component is composed of the even-indexed frequency components,
then the odd half-wave symmetric component must be composed of the odd-indexed
frequency components. Therefore, if an arbitrary function is decomposed into its
even half-wave and odd half-wave symmetric components, then we have divided the
original problem of finding the N frequency coefficients into two problems, each of
them being the determination of N /2 frequency coefficients. First, let us go through
an example of decomposing a periodic function into its even half-wave and odd
half-wave symmetric components.
An arbitrary periodic sequence x(n) of period N can be expressed as the sum of
its even and odd half-wave symmetric components xeh (n) and xoh (n), respectively, as
in which
N N
xeh n ± = xeh (n) and xoh n ± = −xoh (n)
2 2
10.1 Half-Wave Symmetry of Periodic Waveforms 295
(a) (b)
1.7071 1
0.7071
1
x eh(n), x oh(n)
0.2929
x(n)
0 0
-0.2929
-1
-0.7071
-1.7071 -1
0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7
n n
Fig. 10.1 a x(n) = cos( 2π 8 n) + sin(2 8 n); b the odd-indexed frequency component (dots)
2π
Solving for the components using Eqs. (10.1) and (10.2), we get
1 N 1 N
xeh (n) = x(n) + x n ± and xoh (n) = x(n) − x n ±
2 2 2 2
The first is the odd-indexed frequency component and the second is the even-indexed.
Figure 10.1b shows the two components of the waveform x(n). The odd-indexed
component is shown by dots and the even-indexed component is shown by the symbol
∗. The samples of x(n) are
√ √ √ √
2 2 2 2
1, 1 + , 0, − 1 + , −1, 1 − , 0, −1 +
2 2 2 2
It can be verified that x(n) = xeh (n) + xoh (n). The DFT X (k) of x(n) is
{0, 4, 0, 0, 0, 0, 0, 4}
It can be verified that X (k) = Xeh (k) + Xoh (k). Due to the reduction in the num-
ber of frequency components, xeh (n) and xoh (n) can be represented by 4 samples.
The dashed line in the middle of Fig. 10.1b indicates the redundancy of data values
of xeh (n) and xoh (n). The problem of computing the 8-point DFT of x(n) has been
reduced to two problems of 4-point DFTs of xeh (n) and xoh (n). This is the essence
of all the DFT algorithms for sequence lengths those are integral powers of 2. While
the sinusoidal waveforms are easy to visualize, as usual, the DFT problem using
the equivalent complex exponential form is required for further description of the
algorithms.
Recursively carrying out the even and odd half-wave symmetric components
decomposition, along with frequency shifting and decimation of the frequency com-
ponents, the frequency components are eventually isolated yielding their coefficients.
In carrying out these operations, the coefficients are scaled and scrambled but remains
unchanged otherwise. The decomposition of a waveform into its symmetric compo-
nents is the principal operation in the algorithm, requiring repeated execution of add–
subtract (plus–minus) operations. Since the frequency components are decomposed
into smaller groups, this type of algorithms is named as the PM DIF DFT algorithms,
where PM stands for (plus–minus) and DIF stands for (decimation-in-frequency).
For the most compact algorithms, the input sequence x(n) has to be expressed as
2-element vectors
N
a0 (n) = {a00 (n), a10 (n)} = 2 xeh (n), xoh (n), n = 0, 1, . . . , − 1
2
The first and second elements of the vectors are, respectively, the scaled even and
odd half-wave symmetric components xeh (n) and xoh (n) of x(n). That is, the DFT
expression is reformulated as
N −1
x(n)e−j N kn , k = 0, 1, . . . , N − 1
2π
X (k) =
n=0
⎧ (N /2)−1 (N /2)−1
⎪
⎪
N
⎪
⎪ x(n) + x n + e −j 2π kn
= a00 (n)e−j N kn , k even
2π
⎨
N
2
= (Nn=0
/2)−1
n=0
(N /2)−1
⎪
⎪
N
⎪
⎪ x(n) − x n + e−j N kn =
2π
a10 (n)e−j N kn , k odd
2π
⎩
n=0
2 n=0
The division by 2 in finding the symmetric components is deferred. For the example
shown in Fig. 10.1,
3
a00 (n)e−j 8 kn , k = 0, 2, 4, 6
2π
X (k) =
n=0
3
a00 (n)e−j 4 kn , k = 0, 1, 2, 3 = {0, −j4, 0, j4}
2π
=
n=0
3
a10 (n)e−j 8 kn , k = 1, 3, 5, 7
2π
X (k) =
n=0
3
(e−j 8 n a10 (n))e−j 4 kn , k = 0, 1, 2, 3 = {4, 0, 0, 4}
2π 2π
=
n=0
shifting of the DFT spectrum and the odd-indexed coefficients become even-indexed.
Therefore, the 8-point DFT becomes a 4-point DFT. The pointwise product of e−j 8 n
2π
and a1 (n) is
0
√ √ √ √
2 2 2 2 √ √
(e−j 8 n a10 (n))
2π
= 1, −j , −j, − −j (2, 2, 0, − 2)
2 2 2 2
= (2, 1 − j1, 0, 1 + j1)
Then,
{2, 1 − j1, 0, 1 + j1} ↔ {4, 0, 0, 4}
The recursive decomposition is continued until all the individual DFT coefficients
are extracted, as shown in Fig. 10.3.
In terms of the frequency components,
The array of vectors a0 (n) is stored in the nodes at the beginning of the signal-
flow graph of the algorithm shown in Fig. 10.2. Although a DFT algorithm can be
expressed in other forms, the signal-flow graph is the most suitable form for its
description. The repetitive nature of the basic computation is evident. The nodes,
shown by discs, store a vector ar (n). Arrows indicate the signal-flow path. The first
elements of vectors stored in a pair of source nodes produce the vector for the sink
node connected by a upward-pointing arrow by add–subtract operation. Any integer
value n near an arrow indicates that the value from a source node has to be multiplied
by e−j N n before the add–subtract operation. The second elements of vectors stored in
2π
a pair of source nodes produce the vector for the sink node connected by a downward-
pointing arrow. There are log2 N − 1 stages of the algorithm. The input nodes are
source nodes and the output nodes are sink nodes. Rest of the nodes serve both as
source and sink nodes.
Each of the two symmetric components has only four frequency components
and four samples are adequate to represent them. The even half-wave symmetric
component is
2π 2π 2π 2π
2(X (0)ej0 8 n + X (2)ej2 8 n + X (4)ej4 8 n + X (6)ej6 8 n )
2π 2π 2π 2π
= 2(X (0)ej0 4 n + X (2)ej1 4 n + X (4)ej2 4 n + X (6)ej3 4 n ), n = 0, 1, 2, 3
2π 2π 2π 2π
4{X(0)ej0 4 n +X(4)ej2 4 n , X(2)ej1 4 n +X(6)ej3 4 n }, n = 0, 1
Stage 1 Stage 2
a0 (0) A(0) = 8{X(0), X(4)}
0
a0 (1) 2 A(2) = 8{X(2), X(6)}
2π 2π 2π 2π
4{X(1)ej0 4 n +X(5)ej2 4 n , X(3)ej1 4 n +X(7)ej3 4 n }, n = 0, 1
0
a0 (2) A(1) = 8{X(1), X(5)}
2
1
0
a0 (3) A(3) = 8{X(3), X(7)}
3 2
Fig. 10.2 Signal-flow graph of the PM DIF DFT algorithm, with N = 8. A twiddle factor W8n =
2π
e−j 8 n is indicated only by its variable part of the exponent, n
2π 2π 2π 2π
= 2(X (1)ej0 8 n + X (3)ej2 8 n + X (5)ej4 8 n + X (7)ej6 8 n )
2π 2π 2π 2π
= 2(X (1)ej0 4 n + X (3)ej1 4 n + X (5)ej2 4 n + X (7)ej3 4 n ), n = 0, 1, 2, 3
The multiplication by e−j 8 n (called twiddle factor) is the frequency shifting operation
2π
necessary to shift the spectrum to the left by one sample interval. The twiddle factor
is also written as
e−j 8 n = W8n , W8 = e−j 8
2π 2π
Now, the same process is recursively continued. Decomposing the two 4-point
waveforms into their even and odd half-wave symmetric components, we get
2π 2π 2π 2π
4{X (0)ej0 4 n + X (4)ej2 4 n , X (2)ej1 4 n + X (6)ej3 4 n }, n = 0, 1 (10.3)
2π 2π 2π 2π
4{X (1)ej0 4 n + X (5)ej2 4 n , X (3)ej1 4 n + X (7)ej3 4 n }, n = 0, 1 (10.4)
These vector arrays are stored in the middle nodes in the figure.
300 10 Fast Computation of the DFT
The even half-wave symmetric component of the waveform given by Eq. (10.3)
can be expressed as a 2-point DFT
2π 2π
4(X (0)ej0 4 n + X (4)ej2 4 n )
2π 2π
= 4(X (0)ej0 2 n + X (4)ej1 2 n ), n = 0, 1
are obtained by simply adding and subtracting the two sample values. These coeffi-
cients are stored in the top node at the end of the signal-flow graph in the figure.
The odd half-wave symmetric component of the waveform given by Eq. (10.3) is
multiplied by the exponential e−j 8 (2n) = e−j 4 n to get
2π 2π
2π 2π
= 4(X (2)ej0 4 n + X (6)ej2 4 n )
2π 2π
= 4(X (2)ej0 2 n + X (6)ej1 2 n ), n = 0, 1
This is a 2-point DFT with frequency coefficients 4{X (2), X (6)}. The coefficients
are obtained by simply adding and subtracting the two sample values. These coeffi-
cients are stored in the second node from top at the end of the signal-flow graph in
the figure.
The even half-wave symmetric component of the waveform defined by Eq. (10.4)
can be expressed as
2π 2π
4(X (1)ej0 4 n + X (5)ej2 4 n )
2π 2π
= 4(X (1)ej0 2 n + X (5)ej1 2 n ), n = 0, 1
This is a 2-point DFT with frequency coefficients 4{X (1), X (5)}. The coefficients
are obtained by simply adding and subtracting the two sample values. These coeffi-
cients are stored in the third node from top at the end of the signal-flow graph shown
in the figure.
The odd half-wave symmetric component of the waveform defined by Eq. (10.4)
is multiplied by the exponential e−j 4 n to get
2π
10.2 The PM DIF DFT Algorithm 301
2π 2π
= 4(X (3)ej0 4 n + X (7)ej2 4 n )
j0 2π j1 2π
= 4(X (3)e 2 n + X (7)e 2 n ), n = 0, 1
This is a 2-point DFT with frequency coefficients 4{X (3), X (7)}. The coefficients
are obtained by simply adding and subtracting the two sample values. These coef-
ficients are stored in the fourth node from top at the end of the signal-flow graph
shown in the figure.
The output vectors {A(0), A(1), A(2), A(3)} are placed in the bit-reversed order.
This order is obtained by reversing the order of bits of the binary number represen-
tation of the frequency indices. {0, 1, 2, 3} is {00, 01, 10, 11} in binary form. The
bit-reversed {00, 10, 01, 11} in binary form is {0, 2, 1, 3} in decimal form. The bit-
reversed order occurs at the output because of the repeated splitting of the frequency
components into odd- and even-indexed frequency indices groups over the stages of
the algorithm. Efficient algorithms are available to restore the natural order of the
coefficients. In digital signal processing microprocessors, specialized instructions
are available to carry out this task. The extraction of the coefficients, multiplied by
8, of x(n) = cos( 2π
8
n) + sin(2 2π
8
n) is shown in Fig. 10.3.
The number of complex multiplications and additions required for each stage are,
respectively, N /2 and N , where N is the sequence length that is a power of 2. With
(log2 N ) − 1 stages and the initial vector formation requiring N complex additions,
the computational complexity of the algorithm is O(N log2 N ) compared with that of
O(N 2 ) required for the direct computation from√ the DFT definition. Multiplication by
twiddle factors of the forms −j and (1 − j1)/ 2 can be handled separately reducing
the number of operations. If further speed up is required, two adjacent stages of the
algorithm can be implemented together. This reduces the number of data transfers
between the processor registers and the memory yielding significant reduction in the
execution time of the algorithm. In case the number of stages is odd, one stage can
be implemented separately.
The algorithm is so regular that one can easily get the signal-flow graph for any
value of N that is an integral power of 2. The signal-flow graph of the algorithm
is basically an interconnection of butterflies (a computational structure), shown in
Fig. 10.4. The defining equations of a butterfly at the rth stage are given by
Input values
stored in vector Vector formation Stage 1 output Stage 2 output
locations
√
2
x(1) = 1 + 2 a0 (2) = 2 0 X(2) = A0 (2) = −j4
√ √
x(5) = 1 − 2 a1 (2) = 2 4 X(6) = A1 (2) = j4
2
√
2
x(3) = −1− 2 a0 (3) = −2 2 X(3) = A0 (3) = 0
√ √
x(7) = −1+ 22 a1 (3) = − 2 −j2 X(7) = A1 (3) = 4
Fig. 10.3 Trace of the PM DIF DFT algorithm, with N = 8, in extracting the coefficients, scaled
by 8, of x(n) = cos( 2π
8 n) + sin(2 8 n)
2π
n
(r) (r) (r+1) (r+1)
a(r) (l) = {a0 (l), a1 (l)} a(r+1) (l) = {a0 (l), a1 (l)}
N
n+ 4
Fig. 10.4 Signal-flow graph of the butterfly of the PM DIF DFT algorithm, where 0 ≤ n < N
4 .A
−j 2π
twiddle factor WNn =e N n is indicated only by its variable part of the exponent, n
where WNn = e−j N n . There are (log2 N ) − 1 stages, each with N /4 butterflies. With
2π
0
2 ± 4 = {6, −2} {2 + j2, 2 − j2}
1
Fig. 10.5 Computation of a 4-point DFT by the PM DIF DFT algorithm. The twiddle factor
2π
W41 = e−j 4 1 is indicated only by its exponent, 1
The computation of the IDFT can be carried out by a similar algorithm, with the
twiddle factors conjugated. Further, division by N is required. However, the DFT
algorithm itself can be used to carry out the IDFT computation with the interchange
of the real and imaginary parts of the input and output, as shown in Chap. 4. At the
end, division by N is required. Another method is to conjugate the input, compute
its DFT, and conjugate the resulting output.
The computation of a 4-point IDFT by the PM DIF DFT algorithm is as follows.
The input X (k), from the last example, and its conjugate are
X (k) = {10, 2 + j2, −2, 2 − j2} and X ∗ (k) = {10, 2 − j2, −2, 2 + j2}
The input vectors at the 2 nodes of the PM DIF DFT algorithm are, respectively,
Dividing by 4, we get
x(n) = {3, 2, 1, 4}
The input vectors at the 2 nodes of the PM DIF DFT algorithm are, respectively,
x(n) = {3, 2, 1, 4}
Fig. 10.6 Trace of the PM DIF DFT algorithm, with N = 8, in extracting the coefficients, scaled
by 8, of x(n) = cos( 2π
8 n)
10.3 The PM DIT DFT Algorithm 305
Input values
stored in vector Vector formation Stage 1 output Stage 2 output
locations
√
2
x(1) = 2 a0 (2) = 0 0 X(2) = A0 (2) = 0
√ √
x(5) = − 22 a1 (2) = 2 0 X(6) = A1 (2) = 0
√
2
x(3) = 2 a0 (3) = 0 −j2 X(3) = A0 (3) = 0
√ √
x(7) = − 22 a1 (3) = 2 2 X(7) = A1 (3) = j4
Fig. 10.7 Trace of the PM DIF DFT algorithm, with N = 8, in extracting the coefficients, scaled
by 8, of x(n) = sin( 2π
8 n)
The DIT algorithm is based on decomposing the data sequence recursively into
2π
smaller sequences. Consider the exponential x(n) = ej 8 n . The sample values over
one period are
1 1 1 1 1 1 1 1
1, √ + j √ , j1, − √ + j √ , −1, − √ − j √ , −j1, √ − j √
2 2 2 2 2 2 2 2
The samples of x(n) can be expressed as the sum of the upsampled, by a factor of 2,
even-indexed and odd-indexed components
Due to the upsampling theorem (Chap. 3), the DFTs of the upsampled sequences are
the twofold repetition of Xe (k) and Xo (k) and we get
1 1 1 1 1 1 1 1
√ + j √ , 0. − √ + j √ , 0, − √ − j √ , 0, √ − j √ , 0
2 2 2 2 2 2 2 2
√ √ √ √
↔ {0, 2 2 + j2 2, 0, 0, 0, 2 2 + j2 2, 0, 0}
Using the time-shift theorem, we get the DFT of upsampled and shifted xo (n) as
1 1 1 1 1 1 1 1
0, √ + j √ , 0, − √ + j √ , 0, − √ − j √ , 0, √ − j √ ↔
2 2 2 2 2 2 2 2
√ √ √ √
{0, 2 2 + j2 2, 0, 0, 0, 2 2 + j2 2, 0, 0}e−j 8 k
2π
= {0, 4, 0, 0, 0, −4, 0, 0}
10.3 The PM DIT DFT Algorithm 307
2π
Fig. 10.8 Butterfly of the PM DIT DFT algorithm. A twiddle factor WNn = e−j N n is indicated only
by its variable part of the exponent, n
The decomposition continues until the sequence lengths become 1, and the DFT of
the data is itself. There are log2 N stages for a sequence of length N . The computa-
tional complexity of each stage is of the order O(N ). Therefore, the computational
complexity of computing a N -point DFT becomes O(N log2 N ).
The butterfly and the flow graph of the PM DIT DFT algorithm are the transpose
of those of the corresponding DIF algorithms. The PM DIT DFT butterfly is shown
in Fig. 10.8. The butterfly input–output relations at the rth stage are
A(r+1)
0 (h) = A(r) n (r)
0 (h) + WN A0 (l)
A(r+1)
1 (h) = A(r) n (r)
0 (h) − WN A0 (l)
n+ N4
A(r+1)
0 (l) = A(r)
1 (h) + WN A(r)
1 (l)
n+ N
A(r+1)
1 (l) = A(r)
1 (h) − WN 4 A(r)
1 (l),
where n is an integer whose value depends on the stage of computation r and the index
h. The letter A is used to differentiate this butterfly from that of the DIF algorithm.
The flow graph of the PM DIT DFT algorithm with N = 16 is shown in Fig. 10.9.
The trace of the PM DIT DFT algorithm in extracting the coefficient scaled by 8 of
x(n) = sin( 2π
8
n) is shown in Fig. 10.10. While it is possible to draw the flow graph
in alternate ways, the usual ones are for the DIT DFT algorithm to place the input in
the bit-reversed order with the output in the normal order and vice versa for the DIF
DFT algorithm.
308 10 Fast Computation of the DFT
a(4) A(1)
4
2 1
a(2) A(2)
4
0 2
a(6) A(3)
4 6
3
a(1) A(4)
4
0 0
a(5) A(5)
4 5
2
a(3) A(6)
4 6
0
a(7) A(7)
4 6 7
2π
n = e−j 16 n
Fig. 10.9 Flow graph of the PM DIT DFT algorithm with N = 16. A twiddle factor W16
is indicated only by its variable part of the exponent, n
In this approach, we pack two real data sets into one complex data set of the same
length. Let a(n) and b(n) be the two real-valued data sets each of length N . Let the
10.4 Efficient Computation of the DFT of Real Data 309
√
2
x(1) = 2 a0 (2) = 0 −j2 X(1) = A0 (1) = −j4
√
x(5) = − 22 a1 (2) = 2 j2 X(5) = A1 (1) = 0
√
2 √
x(3) = 2 a0 (3) = 0 2(1 − j1) X(3) = A0 (3) = 0
√ √ √
x(7) = − 22 a1 (3) = 2 2(1 + j1) X(7) = A1 (3) = j4
Fig. 10.10 Trace of the PM DIT DFT algorithm, with N = 8 in extracting the coefficient scaled
by 8 of x(n) = sin( 2π
8 n)
respective DFTs be A(k) and B(k). We form the complex data c(n) such that its real
and imaginary parts are, respectively, a(n) and b(n). Let the DFT of c(n) is C(k).
Then, using the linearity property of the DFT,
Solving for A(k) and B(k) from the last two equations, we get
C(k) + C ∗ (N − k) C(k) − C ∗ (N − k)
A(k) = and B(k) = (10.5)
2 j2
The flowchart of the algorithm is shown in Fig. 10.11. The two real input data sets,
each of length N , are read into real arrays a(n) and b(n). The
√ complex data array
c(n) = a(n) + jb(n) is formed, where j is the imaginary unit, −1. The DFT of c(n),
310 10 Fast Computation of the DFT
C(k) = DFT(c(n))
Return
C(k), is computed. The DFTs A(k) and B(k) of a(n) and b(n) are separated from
C(k) using Eq. (10.5). The values A(0), B(0), A(N /2), and B(N /2) are readily taken
from C(k), since their values are real. Only half of the values of A(k) and B(k) are
computed, since the other half is its complex conjugate.
The IDFTs of two DFTs, A(k) and B(k) of real-valued data a(n) and b(n), can
be computed simultaneously. The flowchart of the algorithm is shown in Fig. 10.12.
As the DFTs are conjugate-symmetric, only one half of the values of A(k) and B(k)
are read. The values A(0), B(0), A(N /2), and B(N /2) form the real imaginary parts
of C(0) and C(N /2), since their values are real. The second-half of C(k) is found
using C(N − k) = A∗ (k) + jB∗ (k). As the IDFT of C(k) is c(n) = a(n) + jb(n), the
real and imaginary parts of c(n) are, respectively, a(n) and b(n).
Example 10.1 Compute the DFT of the sequences a(n) = {2, 1, 4, 3} and b(n) =
{1, 2, 2, 3} using a DFT algorithm for complex data of the same length. Verify that
the IDFT of the complex data formed gets back a(n) and b(n).
Solution
Packing the sequences into a complex data, we get
Start
c(n) = IDFT(C(k))
Return
Fig. 10.12 Flowchart of the IDFT algorithm for computing the IDFT of the transform of two
real-valued data sets simultaneously
Therefore,
A(k) = {10, −2 + j2, 2, −2 − j2}, and B(k) = {8, −1 + j1, −2, −1 − j1}
312 10 Fast Computation of the DFT
Given two DFTs, A(k) and B(k), of real-valued data, a(n), b(n), we form A(k) +
jB(k) and compute its IDFT yielding the a(n) and b(n) in the real and imaginary
parts, respectively. For this example,
The computation of the DFT of a single real data set is referred as RDFT. The inverse
DFT of the transform of real data is referred as RIDFT. Since the DFT of real data
is conjugate-symmetric, only one half of the number of butterflies in each stage of
the DFT algorithm for complex-valued data is necessary. The redundant butterflies
can be easily eliminated in the DIT algorithm for complex-valued data in deriving
the corresponding RDFT algorithm. Similarly, the RIDFT algorithm can be derived
from the corresponding DIF algorithm.
The PM DIT RDFT Butterfly
The equations characterizing the input–output relation of the PM DIT RDFT butterfly,
shown in Fig. 10.13, are
where s is an integer whose value depends on the stage of the computation r and the
index h. The butterfly for real data is essentially the same as that for complex data
with some differences. Only half of the butterflies are computed in each group of
butterflies in each stage. Since a butterfly produces one output at the upper-half and
another output at the lower-half of a group of butterflies in each stage, the lower-half
output has to be conjugated and stored in a memory location in the upper-half.
The flow graph of the PM DIT RDFT algorithm with N = 16 is shown in
Fig. 10.14. The trace of the RDFT algorithm for computing the DFT with N = 16 is
shown in Fig. 10.15. The data storage scheme is
N N
x (n) = x(n), x n + , n = 0, 1, . . . , −1
2 2
N N
X (0) = X (0), X and X (k) = X (k), k = 1, . . . , − 1
2 2
As in the DIT DFT algorithms for complex data, in the last stage, two 8-point DFTs
are merged to form a 16-point DFT. The differences are that: (i) only half the number
Fig. 10.14 The flow graph of the PM DIT RDFT algorithm with N = 16
314 10 Fast Computation of the DFT
Fig. 10.15 Trace of the RDFT algorithm for computing the DFT with N = 16
of butterflies are used and (ii) conjugation and swapping operations are required. Due
to the lack of symmetry of the data at the input and output end, special butterflies
are used. The first-stage butterflies, denoted by f , compute 2-point DFTs. The input
and output data are stored as shown in the trace of the algorithm. In addition, the
input is also placed in bit-reversed order. Subsequently, there is a g butterfly for each
group of butterflies. The g butterflies use the values stored in a pair of nodes. Both
the nodes have two real values. The sum and difference of the values stored in the
first locations of the top and bottom nodes, respectively, form the output for the first
and second location of the top node. For example, in the g butterfly of the first stage,
the output values are 1 + 7 = 8 and 1 − 7 = −6. The output value at the bottom
node is the sum of the second value of the top node and the product of the second
value at the bottom node multiplied by −j. For the example, 1 + (−j)(−1) = 1 + j1
is stored in the second node.
The input and output data are stored as shown in the trace of the algorithm. The
input and output for the rest of the butterflies are complex and the computation is as
shown in Fig. 10.13.
Let the input 16-point real data sequence be
{1, 3, 2, 5, 3, 4, 5, 3, 0, 2, 0, 2, 4, 2, 1, 4}
The other values can be obtained using the conjugate symmetry of the DFT of real
data. The even-indexed values xe(n) of x(n) are
xe(n) = {1, 2, 3, 5, 0, 0, 4, 1}
10.4 Efficient Computation of the DFT of Real Data 315
xo(n) = {3, 5, 4, 3, 2, 2, 2, 4}
The last stage output is the first (N /2) + 1 = 9 DFT coefficients. These coeffi-
cients are obtained by merging the 5 DFT coefficients of the two 8-point DFTs. The
whole computation is similar to complex-valued algorithms with few differences.
The PM DIF RIDFT Butterfly
The RIDFT algorithm is derived from the corresponding DIF DFT algorithm for
complex-valued data. Only half of the butterflies of the complex-valued algorithm
are necessary. The RIDFT butterfly is shown in Fig. 10.16. It is similar to that of
the algorithm for complex-valued data, except that the input data at the bottom node
is read from the first-half of the DFT coefficients and conjugated. In addition, the
twiddle factors are conjugated compared with those of the RDFT algorithm. The
equations governing the butterfly are
The flow graph of the RIDFT algorithm with N = 16 is shown in Figure 10.17.
The f butterflies compute a 2-point IDFT, without the division operation by 2, of the
two real values stored in each node. The g butterflies use the values stored in a pair of
nodes. The top node has two real values. The sum and difference of these values are
stored in the first location of the top and bottom nodes, respectively. For example, in
the g butterfly of the first stage, the output values are 41 − 9 = 32 and 41 + 9 = 50.
Let the complex value stored in the bottom node is a + jb. Then, 2a and −2b are
(r)
−s
X (l1) * X (r+1)
(l)
−s−N2
316 10 Fast Computation of the DFT
0 f
X (1) −4 16x (4)
0 g f
X (2) −4 16x (2)
−2 0 f
X (3) 16x (6)
* −10 −4
0 g g f
X (4) 16x (1)
−4
−1 0 f
X (5) 16x (5)
−9 −4
*
−2 0 g f
X (6) * 16x (3)
−10 −4
* −3 −2 0 f
X (7) −11 −10 −4 16x (7)
*
stored in the second location of the top and bottom nodes, respectively. For the first
g butterfly, a + jb = 0 + j3. Therefore, 0 and −6 are stored.
The trace of the RIDFT algorithm is shown in Fig. 10.18. The input DFT coeffi-
cients are the output in Fig. 10.15. The output values have to be divided by 16.
10.5 Summary 317
10.5 Summary
Exercises
10.1 Given the samples of a waveform x(n), find the samples of its even half-wave
symmetric and odd half-wave symmetric components. Verify that the sum of the
samples of the two components add up to the samples of x(n). Compute the DFT
of x(n) and its components. Verify that the DFT of the even half-wave symmetric
component consists of zero-valued odd-indexed spectral values. Verify that the DFT
of the odd half-wave symmetric component consists of zero-valued even-indexed
spectral values.
10.1.1 x(n) = {0̌, 1, 2, 3}.
* 10.1.2 x(n) = {0̌, 1, 0, 1}.
10.1.3 x(n) = {1̌, 3, −1, −3}.
10.1.4 x(n) = {2̌, 1, 3, 4}.
10.1.5 x(n) = {3̌, 1, 2, 4}.
10.2 Given a waveform x(n) with period 8, find the samples of the waveform. (a)
Give the trace of the PM DIF DFT algorithm in computing its DFT X (k). (b) Give
the trace of the PM DIT DFT algorithm in computing its DFT X (k). Verify that both
are the same. In both cases, find the IDFT of X (k) using the same DFT algorithms,
give the trace and verify that the samples of the input x(n) are obtained.
10.2.1 x(n) = −2e−j( 8 n+ 6 )
2π π
10.3 Given two waveforms x(n) and y(n) with period 8, find the samples of the
waveforms. Use the PM DIT DFT algorithm for complex data to find their DFTs
using the algorithm for computing the DFTs of two real data sets simultaneously.
Compute the IDFTs of the DFTs using a DFT algorithm for complex data sets
simultaneously. Verify the DFT X (k) and Y (k) by expressing x(n) and y(n) into its
complex exponential
components.
10.3.1 x(n) = cos 2π 1n + π6 and y(n) = cos 2π 3n − π6 .
2π
8 8
10.3.2 x(n) = cos 8 2n − π6 and y(n) = cos 2π 7n − π3 .
2π 8
10.3.3 x(n) = cos 8 3n + π4 and y(n) = cos 2π 5n − π3 .
2π π
2π
8
10.3.4 x(n) = cos 8 0n + 6 and y(n) = cos 8 6n + π3 .
* 10.3.5 x(n) = cos 2π 8
6n + π4 and y(n) = cos 2π 8
5n − π3 .
10.4 Given a waveform x(n) with period 8, find the samples of the waveform. Find
its DFT X (k) using the PM RDFT algorithm. Find the IDFT of X (k) using the PM
RIDFT algorithm to get back the samples of x(n). Verify the DFT X (k) by expressing
x(n) into its complex exponential components.
10.5 Summary 319
10.4.1 cos 2π 0n + π6 .
2π
8
10.4.2 cos 8 1n − π6 .
10.4.3 cos 2π 8
2n + π4 .
* 10.4.4 cos 2π 3n − π4 .
2π 8
10.4.5 cos 8 4n + π3 .
Appendix A
Transform Pairs and Properties
See Tables A.1, A.2, A.3, A.4, A.5, A.6, A.7, and A.8.
δ(n) 1
1 N δ(k)
2π
j N k0 n
e N δ(k − k0 )
2π
cos N k0 n + θ N
2 (e jθ δ(k − k0 ) + e− jθ δ(k − (N − k0 )))
2π
cos N k0 n N
2 (δ(k − k0 ) + δ(k − (N − k0 )))
2π
sin k0 n N
N
2 (− jδ(k − k0 ) + jδ(k − (N − k0 )))
⎧
⎪
⎨ 1 for n = 0, 1, . . . , L − 1
sin( Nπ k L)
e(− j N (L−1)k )
π
x(n) = sin( Nπ k)
⎪
⎩
0 for n = L , L + 1, . . . , N − 1
Duality 1
N X (N ∓ n) x(N ± k)
2π
Time-shifting x(n ± n 0 ) e± j N n0 k X (k)
2π
Frequency-shifting e∓ j N k0 n
x(n) X (k ± k0 )
N −1
Time-convolution k=0 x(k)h(n − k) X (k)H (k)
1
N −1
Frequency-convolution x(n)h(n) N v=0 X (v)H (k − v)
Time-expansion h(an) =
⎧ H (k) = X (k mod N ),
⎨ x(n) for n = 0, 1, . . . , N − 1 k = 0, 1, . . . , a N − 1
⎪
⎪
⎩
0 otherwise
where a is any positive integer
Time-reversal x(N − n) X (N − k)
Conjugation x ∗ (N ± n) X ∗ (N ∓ k)
N −1 1
N −1
n=0 |x(n)| k=0 |X (k)|
Parseval’s theorem 2 2
N
∞
n=−∞ δ(t − nT )
1
T
e jk0 ω0 t δ(k − k0 )
t X f s (k)
Time-integration −∞ x(τ )dτ jkω0 , if (X f s (0) = 0)
T
∞
Parseval’s theorem 1
T 0 |x(t)|2 dt k=−∞ |X f s (k)|
2
Even symmetry x(t) real and even X f s (k) real and even
Odd symmetry x(t) real and odd X f s (k) imaginary and odd
324 Appendix A: Transform Pairs and Properties
x(n) X (e jω ), Period = 2π
⎧
⎪
⎨ 1 for − N ≤ n ≤ N
sin(ω (2N2+1) )
⎪ sin( ω2 )
⎩
0 otherwise
⎧
⎪
⎨ 1 for |ω| < a
sin(an)
πn , 0<a≤π
⎪
⎩
0 for a < |ω| ≤ π
1−a 2
a |n| , |a| < 1 1−2a cos(ω)+a 2
(a)e− jω sin(ω0 )
a n sin(ω0 n)u(n), |a| < 1 1−2(a)e− jω cos(ω0 )+(a)2 e− j2ω
1−(a)e− jω cos(ω0 )
a n cos(ω0 n)u(n), |a| < 1 1−2(a)e− jω cos(ω0 )+(a)2 e− j2ω
δ(n) 1
∞ ∞
δ(n − k N ) 2π
N δ(ω − 2π
N k)
k=−∞ k=−∞
u(n) πδ(ω) + 1
1−e− jω
1 2πδ(ω)
2
sgn(n) 1−e− jω
e jω0 n 2πδ(ω − ω0 )
k X (e jω )
Frequency-differentiation (n)k x(n) ( j)k d dω k
∞ 2π
n=−∞ |x(n)| |X (e jω )|2 dω
2 1
Parseval’s theorem 2π 0
x(t) X ( jω)
sin(ω0 t)
πt u(ω + ω0 ) − u(ω − ω0 )
ω0
e−at sin(ω0 t)u(t), Re(a) > 0 (a+ jω)2 +ω02
δ(t) 1
∞
∞
n=−∞ δ(t − nT ) k=−∞ δ(ω − k 2π
T )
2π
T
u(t) πδ(ω) + 1
jω
1 2πδ(ω)
2
sgn(t) jω
1 2πδ(ω)
e jω0 t 2πδ(ω − ω0 )
2π (X ( jω) ∗ H ( jω))
1
Frequency-convolution x(t)h(t)
ω
Time-scaling x(at), a = 0 and real |a| X ( j a )
1
t X ( jω)
Time-integration −∞ x(τ )dτ jω + π X ( j0)δ(ω)
n X ( jω)
Frequency-differentiation t n x(t) ( j)n d dω n
∞ ∞
−∞ |x(t)| dt −∞ |X ( jω)|
2 1 2 dω
Parseval’s theorem 2π
Even symmetry x(t) real and even X ( jω) real and even
Odd symmetry x(t) real and odd X ( jω) imaginary and odd
Appendix B
Useful Mathematical Formulas
Trigonometric Identities
Pythagorean Identity
sin2 x + cos2 x = 1
Double-angle Formulas
Product Formulas
2 sin x cos y = sin(x − y) + sin(x + y)
x+y x−y
cos x + cos y = 2 cos cos
2 2
x+y x−y
cos x − cos y = −2 sin sin
2 2
Other Formulas
sin(−x) = sin(2π − x) = − sin x
sin(π ± x) = ∓ sin x
cos(π ± x) = − cos x
π
cos ± x = ∓ sin x
2
π
sin ± x = cos x
2
3π
cos ± x = ± sin x
2
3π
sin ±x = − cos x
2
e± j x = cos x ± j sin x
e j x + e− j x
cos x =
2
e j x − e− j x
sin x =
j2
Series Expansions
x2 x4 x 2r
cos(x) = 1 − + − · · · + (−1)r − ···
2! 4! (2r )!
x3 x5 x 2r +1
sin(x) = x − + − · · · + (−1)r − ···
3! 5! (2r + 1)!
Appendix B: Useful Mathematical Formulas 331
1 x3 (1)(3) x 5 (1)(3)(5) x 7
sin−1 x = x + + + + · · · , |x| < 1
2 3 (2)(4) 5 (2)(4)(6) 7
π
cos−1 x = − sin−1 x, |x| < 1
2
Summation Formulas
N
N (N + 1)
k=
k=0
2
N −1
N (2a + (N − 1)d)
(a + kd) =
k=0
2
N −1
a(1 − r N )
ar k = , r = 1
k=0
1−r
∞
1
rk = , |r | < 1
k=0
1−r
∞
r
kr k = , |r | < 1
k=0
(1 − r )2
1 sin(0.5(2N + 1)t)
1 + cos(t) + cos(2t) + · · · + cos(N t) = +
2 2 sin(0.5t)
Indefinite Integrals
udv = uv − vdu
eat
eat dt =
a
eat
teat dt = (at − 1)
a2
ebt
ebt sin(at)dt = (b sin(at) − a cos(at))
a 2 + b2
ebt
ebt cos(at)dt = (b cos(at) + a sin(at))
a 2 + b2
332 Appendix B: Useful Mathematical Formulas
1
sin(at)dt = − cos(at)
a
1
cos(at)dt = sin(at)
a
1
t sin(at)dt = (sin(at) − at cos(at))
a2
1
t cos(at)dt = (cos(at) + at sin(at))
a2
t 1
sin2 (at)dt = − sin(2at)
2 4a
t 1
cos2 (at)dt = + sin(2at)
2 4a
1 1 t
dt = tan−1 ( )
a2 +t 2 a a
sin((a − b)t) sin((a + b)t)
sin(at) sin(bt)dt = − , a 2 = b2
2(a − b) 2(a + b)
cos((a − b)t) cos((a + b)t)
sin(at) cos(bt)dt = − + , a 2 = b2
2(a − b) 2(a + b)
sin((a − b)t) sin((a + b)t)
cos(at) cos(bt)dt = + , a 2 = b2
2(a − b) 2(a + b)
Differentiation Formulas
d(uv) dv du
=u +v
dt dt dt
d( f (u)) d( f (u)) du
=
dt du dt
d( uv ) v du − u dv
= dt 2 dt
dt v
d(x n )
= nx n−1
dt
d(eat )
= aeat
dt
Appendix B: Useful Mathematical Formulas 333
d(sin(at))
= a cos(at)
dt
d(cos(at))
= −a sin(at)
dt
L’Hôpital’s Rule
If lim f (x) = 0 and lim g(x) = 0, or
x→a x→a
d f (x)
f (x)
lim = lim dx
dg(x)
x→a g(x) x→a
dx
1. E.A. Guillemin, Theory of Linear Physical Systems (Wiley, New York, 1963)
2. E.A. Guillemin, The Mathematics of Circuit Analysis (Wiley, New York, 1959)
3. B.P. Lathi, Linear Systems and Signals (Oxford University Press, New York,
2005)
4. E.O. Brigham, The Fast Fourier Transform and Its Applications (Prentice-Hall,
Englewood Cliffs, 1988)
5. R.N. Bracewell, The Fourier Transform and Its Applications (McGraw-Hill, New
York, 2000)
6. D. Sundararajan, Signals and Systems – A Practical Approach (Wiley, Singapore,
2008)
7. D. Sundararajan, Discrete Fourier Transform, Theory, Algorithms, and Applica-
tions (World Scientific, Singapore, 2001)
8. D. Sundararajan, Discrete Wavelet Transform, A Signal Processing Approach
(Wiley, Singapore, 2015)
9. D. Sundararajan, Digital Image Processing - A Signal Processing Approach
(Springer, Singapore, 2017)
10. The Mathworks, Matlab Image Processing Tool Box User’s Guide (The Math-
works, Inc., U.S.A., 2018)
11. The Mathworks, Matlab Signal Processing Tool Box User’s Guide (The Math-
works, Inc., U.S.A., 2018)
Chapter 1
1.1.2 0.
1.2.3
x(n) = −2δ(n) − δ(n − 2) + 3δ(n + 2) + 3δ(n + 3)
1.3.3
{−1.4575, −1.7292, −1.7320, −1.7321, −1.7321}
1.4.4
371.0329
1.5.1 ⎧
⎨
−2 for n = 1, 0, −1
x(n) =
⎩ 0 otherwise
1.6.5
1.11.4
1.12.3 Neither.
1.13.3 Average power is 2.
1.14.3 x(an + k) = sin( π8 n − π3 ).
Chapter 2
Chapter 3
3.1.2
X (k) = {10, −2 + j2, −2, −2 − j2}, Y (k) = {0, 1 + j3, −10, 1 − j3},
Z (k) = {30, −8, 14, −8}
3.2.3
X (k) = {11, 1, 3, 1}, X (−7) = 1, x(23) = 2
3.3.1
{11, −2 − j1, −3, −2 + j1}
3.4.2
{−3 − j1, 4, −3 + j1, −6}
3.5.2
{2, −4 − j2, −6, −4 + j2}
3.6.3
{16, 4, 8, −8}
340 Answers to Selected Exercises
3.7.3
3.8.1
y(n) = {16, 15, 6, 13}
3.9.2
Y (k) = {5, −1 + j10, 9, −1 − j10}
3.10.2
r xh (n) = {14, 6, 5, 3}
3.11.3
r x x (n) = {18, 5, 8, 5}
3.12.1
X (k) = {7, −1 − j2, −1, −1 + j2}
3.13.3
{1, 7, 1, 7}
3.14.3
{1, 0, −5, 0}
3.15.1
X (k) = {3, −1}, X Z (k) = {3, 1 − j2, −1, 1 + j2}
3.17.2
X (k) = {14, 3 + j1, 0, 3 − j1}
Chapter 4
4.1.1
The DFT is
⎡ ⎤
32 0 0 0
⎢ ⎥
⎢ ⎥
⎢ 0 −20.7846 − j12 0 0⎥
X (k, l) = ⎢ ⎥
⎢ 0 6.9282 − j4 0 6.9282 + j4 ⎥
⎣ ⎦
0 0 0 −20.7846 + 12
4.2.1 ⎡ ⎤
40 −3 + j3 −2 −3 − j3
⎢ ⎥
⎢ ⎥
⎢ 1 + j1 −2 + j2 −7 + j3 j2 ⎥
X (k, l) = ⎢ ⎥
⎢ 5 − j7 5 + j7 ⎥
⎣ 2 4 ⎦
1 − j1 − j2 −7 − j3 −2 − j2
4.4.2
⎡ ⎤
26.00 + j0.00 0.00 + j8.00 −6.00 + j0.00 0.00 − j8.00
⎢ ⎥
⎢ ⎥
⎢ 6.00 + j0.00 −4.00 − j4.00 2.00 − j4.00 −4.00 − j4.00 ⎥
X (k, l) = ⎢ ⎥
⎢ 2.00 + j0.00 0.00 + j0.00 −6.00 + j0.00 0.00 + j0.00 ⎥
⎣ ⎦
6.00 + j0.00 −4.00 + j4.00 2.00 + j4.00 −4.00 + j4.00
342 Answers to Selected Exercises
⎡ ⎤
18.00 + j0.00 3.00 − j3.00 0.00 + j0.00 3.00 + j3.00
⎢ ⎥
⎢ ⎥
⎢ 3.00 + j5.00 −6.00 + j2.00 −5.00 − j1.00 0.00 + j2.00 ⎥
H (k, l) = ⎢ ⎥
⎢ 0.00 + j0.00 −1.00 − j1.00 −6.00 + j0.00 −1.00 + j1.00 ⎥
⎣ ⎦
3.00 − j5.00 0.00 − j2.00 −5.00 + j1.00 −6.00 − j2.00
⎡ ⎤
⎢ 468.00 + j0.00 24.00 + j24.00 −0.00 + j0.00 24.00 − j24.00 ⎥
⎢ ⎥
⎢ 18.00 + j30.00 32.00 + j16.00 −14.00 + j18.00 8.00 − j8.00 ⎥
X (k, l)H (k, l) = ⎢
⎢
⎥
⎥
⎢ 0.00 + j0.00 0.00 + j0.00 36.00 + j0.00 0.00 + j0.00 ⎥
⎣ ⎦
18.00 − j30.00 8.00 + j8.00 −14.00 − j18.00 32.00 − j16.00
⎡ ⎤
40 25 24 37
⎢ ⎥
⎢ ⎥
⎢ 23 24 19 36 ⎥
y(m, n) = ⎢ ⎥
⎢ 29 23 33 23 ⎥
⎣ ⎦
37 33 29 33
⎡ ⎤
⎢ 468.00 + j0.00 −24.00 + j24.00 −0.00 + j0.00 −24.00 − j24.00 ⎥
⎢ ⎥
⎢ 18.00 − j30.00 16.00 + j32.00 −6.00 + j22.00 −8.00 + j8.00 ⎥
X (k, l)H ∗ (k, l) = ⎢
⎢
⎥
⎥
⎢ 0.00 + j0.00 −0.00 + j0.00 36.00 + j0.00 −0.00 + j0.00 ⎥
⎣ ⎦
18.00 + j30.00 −8.00 − j8.00 −6.00 − j22.00 16.00 − j32.00
⎡ ⎤
31 24 35 36
⎢ ⎥
⎢ ⎥
⎢ 20 32 36 44 ⎥
r xh (m, n) = ⎢ ⎥
⎢ 26 24 34 24 ⎥
⎣ ⎦
28 25 24 25
⎡ ⎤
⎢ 468.00 + j0.00 −24.00 − j24.00 −0.00 + j0.00 −24.00 + j24.00 ⎥
⎢ ⎥
⎢ 18.00 + j30.00 16.00 − j32.00 −6.00 − j22.00 −8.00 − j8.00 ⎥
H (k, l)X ∗ (k, l) = ⎢
⎢
⎥
⎥
⎢ 0.00 + j0.00 0.00 + j0.00 36.00 + j0.00 −0.00 + j0.00 ⎥
⎣ ⎦
18.00 − j30.00 −8.00 + j8.00 −6.00 + j22.00 16.00 + j32.00
Answers to Selected Exercises 343
⎡ ⎤
31 36 35 24
⎢ ⎥
⎢ ⎥
⎢ 28 25 24 25 ⎥
rhx (m, n) = ⎢ ⎥
⎢ 26 24 34 24 ⎥
⎣ ⎦
20 44 36 32
⎡ ⎤ ⎡ ⎤
676 64 36 64 70 40 38 40
⎢ ⎥ ⎢ ⎥
⎢ ⎥ ⎢ ⎥
∗ ⎢ 36 32 20 32 ⎥ ⎢ 50 42 34 42 ⎥
X (k, l)X (k, l) = ⎢ ⎥ r x x (m, n) = ⎢ ⎥
⎢ 4 0 36 0 ⎥ ⎢ 40 36 40 36 ⎥
⎣ ⎦ ⎣ ⎦
36 32 20 32 50 42 34 42
Chapter 5
5.1.3
The input sequences are zero padded.
⎡ ⎤
4 4 − j8 −12 4 + j8
⎢ ⎥
⎢ ⎥
⎢ −7 − j17 1 + j3 −7 + 11 29 + j3 ⎥
Y (k, l) = X (k, l)H (k, l) = ⎢ ⎥
⎢ −30 10 + j20 10 10 − j20 ⎥
⎣ ⎦
−7 + j17 29 − j3 −7 − j11 1 − j3
⎡ ⎤
2 −3 −9 0
⎢ ⎥
⎢ ⎥
⎢ 0 14 3 0⎥
y(m, n) = IDFT(Y (k, l)) = ⎢ ⎥
⎢ −2 −3 2 0⎥
⎣ ⎦
0 0 0 0
⎡ ⎤
2 −8 + j6 −18 −8 − j6
⎢ ⎥
⎢ ⎥
⎢ −26 − j12 0 −8 − j6 −34 − j18 ⎥
Y (k, l) = X (k, l)H ∗ (k, l) = ⎢ ⎥
⎢ −54 −26 + j12 2 −26 − j12 ⎥
⎣ ⎦
−26 + j12 −34 + j18 −8 + j6 0
⎡ ⎤
−17 −9 0 0
⎢ ⎥
⎢ ⎥
⎢ 9 2 0 9⎥
r xh (m, n) = IDFT(Y (k, l)) = ⎢ ⎥
⎢ 0⎥
⎣ 0 0 0 ⎦
0 9 0 −1
5.5.2
X (k) = {8, 1 + j3, −2, 1 − j3}, H (k) = {0, − j, 0, j}
Chapter 6
6.1.1
6.2.2
x4 (n) = x12 (n) = {−1.7321, 1.7321, −1.7321, 1.7321, −1.7321, 1.7321, −1.7321, 1.7321}
6.3.3
wr (n) = {1, 1, 1, 1, 1, 0, 0, 0}
X (k) = {0, 0, 0, 4, 0, 4, 0, 0}
6.4.4
whan (n) = {0, 0.3455, 0.9045, 0.9045, 0.3455, 0, 0, 0}
Chapter 7
7.1.3
ω0 = 1.
7.2.2 After canceling common factors, the frequency of the waveforms is 21 and 29 .
The LCM of the denominators (2,9) is 18. The GCD of the numerators (1,2) is 1.
Therefore, the fundamental frequency is ω0 = 181
rad/s. The fundamental period is
T = ω0 = 1 = 36π. The first sinusoid is the 9th harmonic. The second sinusoid
2π 2π18
7.3.1
1 a − jkω0 t
X f s (k) = e dt
T −a
1 −1 − jkω0 t a 1 −1 − jkω0 a
= e −a = (e − e jkω0 a )
T jkω0 T jkω0
2 1 2 sin(kω0 a)
= (e jkω0 a − e− jkω0 a ) =
T j2kω0 T kω0
sin(0.4kπ)
X f s (k) =
kπ
348 Answers to Selected Exercises
∞
sin(0.4kπ) jk0.2πt
x(t) = e
k=−∞
kπ
7.4.1
∞
2 4 1 π
x(t) = + cos 2k t − =
π π k=1 1 − 4k 2 2
2 4 π 4 π 4 π
− cos 2 t − − cos 4 t − − cos 6 t − + ···
π 3π 2 15π 2 35π 2
2 4 4 4
= + cos(2t) − cos(4t) + cos(6t) + · · ·
π 3π 15π 35π
7.5.2 With Ts = 1, the samples are
Chapter 8
8.2
j2 (sin(2ω)) = (e j2ω − e− j2ω ) ↔ δ(n + 2) − δ(n − 2)
8.4
X (e jω ) = 3 + e− jω + 2e− j2ω and H (e jω ) = 1 + 2e− jω + 4e− j2ω
{3, 7, 16, 8, 8}
8.6
Answers to Selected Exercises 349
2π
2π ej 8
H (e j 8 ) = 2π = 0.6350∠(0.3197)
+ 0.7
ej 8
2π π
y(n) = 0.6350 sin n − + 0.3197
8 6
8.8
y(n) = −3(−0.6)n + 4(−0.8)n u(n)
8.10.1
X (e jω ) = 2e j2ω + e jω + 3 + 4e− jω
{7.5, 0.75 − j4.75, 1.75 − j0.25, 1 + j4, 1.5, 0.25 + j0.75, −0.75 + j0.25}
The circular convolution output can be obtained by adding the last three terms with
the first three terms.
Chapter 9
9.2
2 + jω
(2 + jω)2 + 9
9.5.1
j
X f s (0) = 0.5 and X f s (k) = , k = 0
2kπ
350 Answers to Selected Exercises
9.6.2
1 1
πδ(t) + ↔ u(−ω)
2π jt
9.7.3
sin((ω − 3)2) sin((ω + 3)2)
X ( jω) = − j −
(ω − 3) (ω + 3)
9.8.2
1 1
5 + jω 4 + jω
9.9.1
π jω
(δ(ω − 3) + δ(ω + 3)) − 2
2 (ω − 32 )
9.10.3
− j2ω 1
e πδ(ω) +
jω
9.11.3
e− j2ω 1 e− j2ω
X ( jω) = −2 − 2+
jω ω ω2
1 e− j2ω
jω X ( jω) = −2e− j2ω + −
jω jω
9.12.3
0.5 0.5
0.5πδ(ω) + −
jω 2 + jω
9.14.1
2π π 2π π − j π3 2π j π3 2π
sin t+ = cos t− ↔π e δ ω− +e δ ω+
8 6 8 3 8 8
9.15.1
sin(5ω)
u(t + 5) − u(t − 5) ↔ 2
ω
Ts = 1.
Answers to Selected Exercises 351
∞
xs (t) = (u(n + 5) − u(n − 5))δ(t − n) ↔
n=−∞
∞
sin(5(ω + 2kπ))
X s ( jω) = 2
k=−∞
ω + 2kπ
Ts = 0.5.
∞
xs (t) = (u(0.5n + 5) − u(0.5n − 5))δ(t − 0.5n) ↔
n=−∞
∞
sin(5(ω + 4kπ))
X s ( jω) = 2 2
k=−∞
ω + 4kπ
0.5e j5ω + e j4ω + e j3ω + e j2ω + e jω + 1 + e− jω + e− j2ω + e− j3ω + e− j4ω + 0.5e− j5ω
For Ts = 0.5, 21 terms are required. With Ts = 1, the samples of X ( jω) and those
of the 2 sampled versions are, respectively,
9.16.3
∞
2π π
xs (t) = 2 cos 3 (0.5n) + δ(t − 0.5n) ↔
n=−∞
8 3
∞
2π π 2π π 2π
X s ( jω) = 16e j 3 δ ω − 3 − 4mπ + 16e− j 3 δ ω + 3 − 4mπ
(0.5)(16) m=−∞ 8 8
9.19
y(t) = (0.25e−t + 0.75e−3t − 3.5te−3t )u(t)
352 Answers to Selected Exercises
9.20.1
1
X ( jω) =
1 + jω
9.21.1
1
X ( jω) =
1.5 + jω
Chapter 10
10.1.2
xe(n) = {0, 1, 0, 1}, xo(n) = {0, 0, 0, 0}
X (k) = {2, 0, −2, 0}, X e(k) = {2, 0, −2, 0}, X o(k) = {0, 0, 0, 0}
10.2.3
10.3.5
x(n) + j y(n) =
X (k) + jY (k) = {0, 0, 2.8284 − j2.8284, −3.4641 + j2, 0, 3.4641 + j2, 2.8284 + j2.8284, 0}
10.4.4
P
G Paley-Wiener criterion, 284
Parseval’s theorem, 109
Gibbs phenomenon, 193
for DFT, 74
for DTFT, 238
for FS, 203
H for FT, 270
Half-wave symmetry, 196 Periodic signals, 13
Hilbert transform, 243 Picket-fence effect, 174
Polynomial multiplication, 116
Power signal, 17
I
Ideal filters R
lowpass, 283 Radians, 5
Paley-Wiener criterion, 284 Random, 18
IDFT, 35 Rectangular window, 246
center-zero format, 40
definition, 39
matrix form, 42 S
IDFT using the DFT, 90 Sampling theorem, 162
Imaginary unit, 22 Sgn function, 226
Impulse, 224 Signals
Impulse response, 114, 239, 282, 292 aperiodic, 13
Impulse signal band-limited, 162
sifting property, 2, 3 causal, 19
Index 359