Structure and Interpretation of Signals and Systems by Edward Ashford Lee and Pravin Varaiya - HTML preview

PLEASE NOTE: This is an HTML preview only and some elements such as links or page numbers may be incorrect.
Download the book in PDF, ePub for a complete version.

0

otherwise

286

Lee & Varaiya, Signals and Systems

7. FREQUENCY DOMAIN

In other words, y (t) is simply y(t) inside its domain, and zero elsewhere. Then the

periodic signal can be given by1

x(t) =

y (t − mp)

(7.3)

m=−∞

where p = b −a. This is called a shift-and-add summation, illustrated in Figure 7.6. The

periodic signal is a sum of versions of y (t) that have been shifted in time by multiples of

p. Do not let the infinite sum intimidate: all but one of the terms of the summation are zero

for any fixed t! Thus, a periodic signal can be defined in terms of a finite signal, which

represents one period. Conversely, a finite signal can be defined in terms of a periodic

signal (by taking one period).

We can check that x given by (7.3) is indeed periodic with period p,

x(t + p)

=

∑ y (t + p − mp) = ∑ y (t − (m − 1)p)

m=−∞

m=−∞

=

∑ y (t − kp) = x(t),

k=−∞

by using a change of variables, k = m − 1.

It is also important to note that the periodic signal x agrees with y in the finite domain

[a, b] of y, since

∀t ∈ [a,b] x(t) =

∑ y (t − mp)

m=−∞

=

y (t) + ∑ y (t − mp)

m=0

=

y(t),

because, by (7.2), for t ∈ [a, b], y (t) = y(t) and y (t − mp) = 0 if m = 0.

We will see that any periodic signal, and hence any finite signal, can be described as a sum

of sinusoidal signals. This result, known as the Fourier series, is one of the fundamental

tools in the study of signals and systems.

1If this notation is unfamiliar, see box on page 77.

Lee & Varaiya, Signals and Systems

287

7.4. PERIODIC AND FINITE SIGNALS

y' ( t + p)

t

y' ( t)

t

a

p b

y' ( t ! p)

t

"

y' ( t ! 2 p)

t

x( t)

...

...

t

p

Figure 7.6: By repeating the finite signal y we can obtain a periodic signal x.

288

Lee & Varaiya, Signals and Systems

7. FREQUENCY DOMAIN

7.5

Fourier series

A remarkable result, due to Joseph Fourier, 1768-1830, is that a periodic signal x : R → R

with period p ∈ R can (usually) be described as a constant term plus a sum of sinusoids,

x(t) = A0 + ∑ Ak cos(kω0t + φk)

(7.4)

k=1

This representation of x is called its Fourier series. The Fourier series is widely used

for signal analysis. Each term in the summation is a cosine with amplitude Ak and phase

φk. The particular values of Ak and φk depend on x, of course. The frequency ω0, which

has units of radians per second (assuming the domain of x is in seconds), is called the

fundamental frequency, and is related to the period p by

ω0 = 2π/p.

In other words, a signal with fundamental frequency ω0 has period p = 2π/ω. The con-

stant term A0 is sometimes called the DC term, where “DC” stands for direct current, a

reference back to the early applications of this theory in electrical circuit analysis. The

terms where k ≥ 2 are called harmonics.

Equation (7.4) is often called the Fourier series expansion for x because it expands x in

terms of its sinusoidal components.

If we had a facility for generating individual sinusoids, we could use the Fourier series

representation (7.4) to synthesize any periodic signal. However, using the Fourier series

expansion for synthesis of periodic signals is problematic because of the infinite summa-

tion. But for most practical signals, the coefficients Ak become very small (or even zero)

for large k, so a finite summation can be used as an approximation. A finite Fourier

series approximation with K + 1 terms has the form

K

˜

x(t) = A0 + ∑ Ak cos(kω0t + φk).

(7.5)

k=1

The infinite summation of (7.4) is, in fact, the limit of (7.5) as K goes to infinity. We need to be concerned, therefore, with whether this limit exists. The Fourier series expansion

is valid only if it exists. There are some technical mathematical conditions on x that, if

satisfied, ensure that the limit exists (see boxes on pages 295 and 296). Fortunately, these conditions are met almost always by practical, real-world time-domain signals.

Lee & Varaiya, Signals and Systems

289

7.5. FOURIER SERIES

ideal

1.0

K=1

K = 3

0.5

K = 7

K = 32

0.0

-0.5

-1.0

0

1

2

3

4

5

6

7

8

-3

Time in seconds

x10

(a)

1.2

1.0

0.8

0.6

0.4

0.2

0.0

0.0

0.5

1.0

1.5

2.0

2.5

3.0

3.5

4.0

3

Frequency in Hz

x10

(b)

Figure 7.7: (a) One cycle of a square wave and some finite Fourier series ap-

proximations. (b) The amplitudes of the Fourier series terms for the square wave.

290

Lee & Varaiya, Signals and Systems

7. FREQUENCY DOMAIN

Example 7.4: Figure 7.7 shows a square wave with period 8 msec and some finite

Fourier series approximations to the square wave. Only one period of the square

wave is shown. The method for constructing these approximations will be covered

in detail in Chapter 10. Here, we will just observe the general structure of the

approximations.

Notice in Figure 7.7(a) that the K = 1 approximation consists only of the DC term

(which is zero in this case) and a sinusoid with an amplitude slightly larger than

that of the square wave. Its amplitude is depicted in Figure 7.7(b) as the height

of the largest bar. The horizontal position of the bar corresponds to the frequency

of the sinusoid, 125 Hz, which is 1/(8 msec), the fundamental frequency. The

K = 3 waveform is the sum of the K = 1 waveform and one additional sinusoid

with frequency 375 Hz and amplitude equal to the height of the second largest bar

in Figure 7.7(b).

A plot like that in Figure 7.7(b) is called a frequency domain representation of the square

wave, because it depicts the square wave by the amplitude and frequency of its sinusoidal

components. Actually, a complete frequency domain representation also needs to give the

phase of each sinusoidal component.

Notice in Figure 7.7(b) that all even terms of the Fourier series approximation have zero

amplitude. Thus, for example, there is no component at 250 Hz. This is a consequence of

the symmetry of the square wave, although it is beyond the scope of work now to explain

exactly why.

Also notice that as the number of terms in the summation increases, the approximation

more closely resembles a square wave, but the amount of its overshoot does not appear

to decrease. This is known as Gibb’s phenomenon. In fact, the maximum difference

between the finite Fourier series approximation and the square wave does not converge

to zero as the number of terms in the summation increases. In this sense, the square

wave cannot be exactly described with a Fourier series (see box on page 295). Intuitively,

the problem is due to the abrupt discontinuity in the square wave when it transitions

between its high value and its low value. In another sense, however, the square wave is

accurately described by a Fourier series. Although the maximum difference between the

approximation and the square wave does not go to zero, the mean square error does go

to zero (see box on page 296). For practical purposes, mean square error is an adequate

Lee & Varaiya, Signals and Systems

291

7.5. FOURIER SERIES

criterion for convergence, so we can work with the Fourier series expansion of the square

wave.

Example 7.5:

Figure 7.8 shows some finite Fourier series approximations for a

triangle wave. This waveform has no discontinuities, and therefore the maximum

error in the finite Fourier series approxination converges to zero (see box on page

295). Notice that its Fourier series components decrease in amplitude much more

rapidly than those of the square wave. Moreover, the time-domain approximations

appear to be more accurate with fewer terms in the finite summation.

Many practical, real-world signals, such as audio signals, do not have discontinuities, and

thus do not exhibit the sort of convergence problems exhibited by the square wave (Gibbs

phenomenon). Other signals, however, such as images, are full of discontinuities. A (spa-

tial) discontinuity in an image is simply an edge. Most images have edges. Nonetheless,

a Fourier series representation for such a signal is almost always still valid, in a mean

square error sense (see box on page 296). This is sufficient for almost all engineering

purposes.

Example 7.6: Consider an audio signal given by

s(t) = sin(440 × 2πt) + sin(550 × 2πt) + sin(660 × 2πt).

This is a major triad in a non-well-tempered scale. The first tone is A-440. The

third is approximately E, with a frequency 3/2 that of A-440. The middle term is

approximately C , with a frequency 5/4 that of A-440. It is these simple frequency

relationships that result in a pleasant sound. We choose the non-well-tempered

scale because it makes it much easier to construct a Fourier series expansion for

this waveform. We leave the more difficult problem of finding the Fourier series

coefficients for a well-tempered major triad to Exercise 5.

To construct the Fourier series expansion, we can follow these steps:

1. Find p, the period. The period is the smallest number p > 0 such that s(t) =

s(t − p) for all t in the domain. To do this, note that

sin(2π f t) = sin(2π f (t − p))

292

Lee & Varaiya, Signals and Systems

7. FREQUENCY DOMAIN

1.0

ideal

K = 1

0.5

K = 3

K = 7

K = 32

0.0

-0.5

-1.0

0

1

2

3

4

5

6

7

8

-3

Time in seconds

x10

(a)

0.8

0.6

0.4

0.2

0.0

0.0

0.5

1.0

1.5

2.0

2.5

3.0

3.5

4.0

3

Frequency in Hz

x10

(b)

Figure 7.8: (a) One cycle of a triangle wave and some finite Fourier series approx-

imations. (b) The amplitudes of the Fourier series terms for the triangle wave.

Lee & Varaiya, Signals and Systems

293

7.5. FOURIER SERIES

if f p is an integer. Thus, we want to find the smallest p such that 440p,

550p, and 660p are all integers. Equivalently, we want to find the largest

fundamental frequency f0 = 1/p such that 440/ f0, 550/ f0, and 660/ f0 are

all integers. Such an f0 is called the greatest common divisor of 440, 550,

and 660. This can be computed using the gcd function in Matlab. In this

case, however, we can do it in our heads, observing that f0 = 110.

2. Find A0, the constant term. By inspection, there is no constant component in

s(t), only sinusoidal components, so A0 = 0.

3. Find A1, the fundamental term. By inspection, there is no component at 110

Hz, so A1 = 0. Since A1 = 0, φ1 is immaterial.

4. Find A2, the first harmonic. By inspection, there is no component at 220 Hz,

so A2 = 0.

5. Find A3. By inspection, there is no component at 330 Hz, so A3 = 0.

6. Find A4. There is a component at 440 Hz, sin(440 × 2πt). We need to find A4

and φ4 such that

A4 cos(440 × 2πt + φ4) = sin(440 × 2πt).

By inspection, φ4 = −π/2 and A4 = 1.

7. Similarly determine that A5 = A6 = 1, φ5 = φ6 = −π/2, and that all other

terms are zero.

Putting this all together, the Fourier series expansion can be written

6

s(t) = ∑ cos(kω0t − π/2)

k=4

where ω0 = 2π f0 = 220π.

The method used in the above example for determining the Fourier series coefficients is

tedious and error prone, and will only work for simple signals. We will see much better

techniques in chapters 8 and 10.

294

Lee & Varaiya, Signals and Systems

7. FREQUENCY DOMAIN

Probing Further: Uniform convergence

The Fourier series representation of a periodic signal x is a limit of a sequence of func-

tions xN for N = 1, 2, · · · where

N

∀ t ∈ R, xN(t) = A0 + ∑ Ak cos(kω0t +φk).

k=1

Specifically, for the Fourier series representation to be valid, we would like that for all

t ∈ R,

x(t) = lim xN(t).

N→∞

A strong criterion for validity of the Fourier series is uniform convergence of this limit,

in which for each real number ε > 0, there exists a positive integer M such that for all

t ∈ R and for all N > M,

|x(t) − xN(t)| < ε

A sufficient condition for uniform convergence is that the signal x be continuous and

that its first derivative be piecewise continuous.

A square wave, for example, is not continuous, and hence does not satisfy this suffi-

cient condition. Indeed, the Fourier series does not converge uniformly, as you can see

in figure 7.7 by observing that the peak difference between x(t) and xK(t) does not de-

crease to zero. A triangle wave, however, is continuous, and has a piecewise continuous

first derivative. Thus, it does satisfy the sufficient condition. Its Fourier series approx-

imation will therefore converge uniformly, as suggested in Figure 7.8. A weaker, but

still useful, criterion for validity of the Fourier series is considered on page 296. That

criterion is met by the square wave.

See for example R. G. Bartle, The Elements of Real Analysis, Second Edition, John

Wiley & Sons, 1976, p. 117 (for uniform convergence) and p. 337 (for this sufficient

condition).

Lee & Varaiya, Signals and Systems

295

7.5. FOURIER SERIES

Probing Further: Mean square convergence

The Fourier series representation of a periodic signal x with period p is a limit of a

sequence of functions xN for N = 1, 2, · · · where

N

∀ t ∈ R, xN(t) = A0 + ∑ Ak cos(kω0t +φk).

k=1

Specifically, for the Fourier series representation to be valid, we would like that for all

t ∈ R,

x(t) = lim xN(t).

N→∞

For some practical signals, such as the square wave of figure 7.7, this statement is not

quite true for all t ∈ R. For practical purposes, however, we don’t really need for this

to be true. A weaker condition for validity of the Fourier series is that the total energy

in the error over one period be zero. Specifically, we say that xN(t) converges in mean

square to x(t) if

p

Z

lim

|x(t) − xN(t)|2dt = 0.

N→∞

0

The integral here is the energy in the error x(t) − xN(t) over one period. It turns out that

if x itself has finite energy over one period, then xN(t) converges in mean square to x(t).

That is, all we need is that

p

Z

|x(t)|2dt < ∞.

0

Virtually all signals with any engineering importance satisfy this criterion. Note that

convergence in mean square does not guarantee that at any particular t ∈ R, x(t) =

lim xN(t). For a condition that (almost) ensures this for all practical signals, see box on

N→∞

page 297.

See for example R. V. Churchill, Fourier Series and Boundary Value Problems, Third

Edition, McGraw-Hill Book Company, New York, 1978.

296

Lee & Varaiya, Signals and Systems

7. FREQUENCY DOMAIN

7.5.1

Uniqueness of the Fourier series

Suppose x : R → R is a periodic function with period p. Then the Fourier series expansion

is unique. In other words if it is both true that

x(t) = A0 + ∑ Ak cos(kω0t + φk)

k=1

Probing Further: Dirichlet conditions

The Fourier series representation of a periodic signal x with period p is a limit of a

sequence of finite Fourier series approximations xN for N = 1, 2, · · · . We have seen in

the box on page 295 a strong condition that ensures that ∀ t ∈ R,

x(t) = lim xN(t).

(7.6)

N→∞

We have seen in the box on page 296 a weaker condition that does not guarantee this,

but instead guarantees that the energy in the error over one period is zero. It turns that

for almost all signals of interest, we can assert that (7.6) holds for almost all t ∈ R.

In particular, if the Dirichlet conditions are satisfied, then (7.6) holds for all t except

where x is discontinuous. The Dirichlet conditions are three:

• Over one period, x is absolutely integrable, meaning that

p

Z

|x(t)|dt < ∞.

0

• Over one period, x is of bounded variation, meaning that there are no more than

a finite number of maxima or minima. That is, if the signal is oscillating between

high and low values, it can only oscillate a finite number of times in each period.

• Over one period, x is continuous at all but a finite number of points.

These conditions are satisfied by the square wave, and indeed by any signal of practical

engineering importance.

Lee & Varaiya, Signals and Systems

297

7.5. FOURIER SERIES

and

x(t) = B0 + ∑ Bk cos(kω0t + θk),

k=1

where ω0 = 2π/p, then it must also be true that

∀ k ≥ 0, Ak = Bk and φk mod 2π = θk mod 2π.

(The modulo operation is necessary because of the non-uniqueness of phase.) Thus, when

we talk about the frequency content of a signal, we are talking about something that

is unique and well defined. For a suggestion about how to prove this uniqueness, see

problem 11.

7.5.2

Periodic, finite, and aperiodic signals

We have seen in Section 7.4 that periodic signals and finite signals have much in common.

One can be defined in terms of the other. Thus, a Fourier series can be used to describe

a finite signal as well as a periodic one. The “period” is simply the extent of the finite

signal. Thus, if the domain of the signal is [a, b] ⊂ R, then p = b − a. The fundamental

frequency, therefore, is just ω0 = 2π/(b − a).

An aperiodic signal, like an audio signal, can be partitioned into finite segments, and a

Fourier series can be constructed from each segment.

Example 7.7:

Consider the train whistle shown in Figure 7.9(a). Figure 7.9(b)

shows a segment of 16 msec. Notice that within this segment, the sound clearly has

a somewhat periodic structure. It is not hard to envision how it could be described

as sums of sinusoids. The magnitudes of the Ak Fourier series coefficients for this

16 msec segment are shown in Figure 7.9(c). These are calculated on a computer

using techniques we will discuss later, rather than being calculated by hand as in

the previous example. Notice that there are three dominant frequency components

that give the train whistle its tonality and timbre.

298

Lee & Varaiya, Signals and Systems

7. FREQUENCY DOMAIN

0.4

0.2

0.0

-0.2

-0.4

0.0

0.2

0.4

0.6

0.8

1.0

1.2

1.4

1.6

Time in seconds

(a)

0.2

0.1

0.0

-0.1

-0.2

0.0

0.2

0.4

0.6

0.8

1.0

1.2

1.4

1.6

-2

x10

(b)

0.10

0.08

0.06

0.04

0.02

0.00

0.0

0.5

1.0

1.5

2.0

2.5

3.0

3.5

4.0

3

x10

(c)

Figure 7.9: (a) A 1.6 second train whistle. (b) A 16 msec segment of the train

whistle. (c) The Fourier series coefficients for the 16 msec segment.

Lee & Varaiya, Signals and Systems

299

7.6. DISCRETE-TIME SIGNALS

7.5.3

Fourier series approximations to images

Images are invariably finite signals. Given any image, it is possible to construct a periodic

image by just tiling a plane with the image. Thus, there is again