Chapter 1
Introduction

U. Zölzer

In this first chapter, we will introduce the basics of signals and systems, and describe the transmission of signals through these systems [Opp14]. These fundamental concepts and the describing algorithms lay the foundation for digital audio signal processing. We will start with analog signals and analog systems, then we will sample the analog signals and perform digital signal processing, and finally reconstruct an analog output signal from the digital output signal. Figure 1.1 shows a typical audio application of capturing a vocalist and transmission to a loudspeaker via an amplifier for reproduction in another room for a listener or listening audience. The microphone delivers an electrical input signal x left-parenthesis t right-parenthesis and the output signal y left-parenthesis t right-parenthesis is the signal that will be received by the listener's ear. Both signals are continuous‐time input and output signals. The entire chain of operations from microphone, amplifier, loudspeaker, and sound transmission through the listening room to the listener can be modeled by a system with a continuous‐time impulse response h left-parenthesis t right-parenthesis. Such an impulse response can be acquired by an impulse response measurement approach. The entire continuous‐time approach description can also be represented by a discrete‐time approach through sampling the microphone signal x left-parenthesis n right-parenthesis, using the discrete‐time impulse response h left-parenthesis n right-parenthesis, and then delivering the output signal y left-parenthesis n right-parenthesis. Both continuous‐time and discrete‐time signal‐processing techniques [Opp10, Opp14] will be introduced in the following sections.

1.1 Continuous‐time Signals and Convolution

Continuous‐time signals x left-parenthesis t right-parenthesis, as shown in Fig. 1.2, can be used as test signals to analyze the behavior of the response of a physical system to an excitation signal. We need a few simple test signals that will allow for the derivation of all important relations to obtain the input/output description of an input signal transformed to an output signal (handclap right-arrow acoustical transmission through room right-arrow received by human ear). The rectangular (rect) function is defined by

Schematic illustration of audio capturing and reproduction for a listener, and representations of the operations by a signal and system model with input and output signals and by a system represented by an impulse response.

Figure 1.1 Audio capturing and reproduction for a listener, and representations of the operations by a signal and system model with input and output signals and by a system represented by an impulse response.

Schematic illustration of continuous-time signals x1(t)=rect(t), x2(t)=δ(t), x3(t)=ε(t), x4(t)=x2(t-0.5), x5(t)=x2(t-1), and x6(t)=exp(-at)·ε(t).

Figure 1.2 Continuous‐time signals x 1 left-parenthesis t right-parenthesis equals rect left-parenthesis t right-parenthesis, x 2 left-parenthesis t right-parenthesis equals delta left-parenthesis t right-parenthesis, x 3 left-parenthesis t right-parenthesis equals epsilon left-parenthesis t right-parenthesis, x 4 left-parenthesis t right-parenthesis equals x 2 left-parenthesis t minus 0.5 right-parenthesis, x 5 left-parenthesis t right-parenthesis equals x 2 left-parenthesis t minus 1 right-parenthesis, and x 6 left-parenthesis t right-parenthesis equals exp left-parenthesis minus a t right-parenthesis dot epsilon left-parenthesis t right-parenthesis.

(1.1)rect left-parenthesis StartFraction t Over upper T EndFraction right-parenthesis equals Start 2 By 3 Matrix 1st Row 1st Column upper T 2nd Column for 3rd Column StartAbsoluteValue t EndAbsoluteValue less-than StartFraction upper T Over 2 EndFraction comma 2nd Row 1st Column 0 2nd Column for 3rd Column StartAbsoluteValue t EndAbsoluteValue greater-than StartFraction upper T Over 2 EndFraction period EndMatrix

The Dirac impulse delta left-parenthesis t right-parenthesis is defined by

(1.2)delta left-parenthesis t right-parenthesis equals limit Underscript upper T right-arrow 0 Endscripts StartFraction 1 Over upper T EndFraction rect left-parenthesis StartFraction t Over upper T EndFraction right-parenthesis right double arrow integral Subscript negative infinity Superscript infinity Baseline delta left-parenthesis t right-parenthesis d t equals 1 period

The step function is defined by

(1.3)epsilon left-parenthesis t right-parenthesis equals Start 2 By 3 Matrix 1st Row 1st Column 0 2nd Column for 3rd Column t less-than 0 comma 2nd Row 1st Column 1 2nd Column for 3rd Column t greater-than 0 period EndMatrix

A general signal x left-parenthesis t right-parenthesis can be written using the sampling property of the Dirac impulse as

Continuous‐time systems transform the input x left-parenthesis t right-parenthesis to the output y left-parenthesis t right-parenthesis equals script upper T left-brace x left-parenthesis t right-parenthesis right-brace. A time‐domain description can be given by the following signal flow graph: x left-parenthesis t right-parenthesis right-arrow StartLayout 1st Row h left-parenthesis t right-parenthesis EndLayout right-arrow y left-parenthesis t right-parenthesis. The system parameter inside the box is called the impulse response h left-parenthesis t right-parenthesis equals script upper T left-brace delta left-parenthesis t right-parenthesis right-brace of the system. It describes the output of the system y left-parenthesis t right-parenthesis when the input is the Dirac x left-parenthesis t right-parenthesis equals delta left-parenthesis t right-parenthesis. Using Eq. (1.4), we can easily derive that the input/output relation of a system with impulse response h left-parenthesis t right-parenthesis is given by the integral (sliding the folded impulse response h left-parenthesis t minus tau right-parenthesis along the input and performing weighting and integration)

(1.5)StartLayout 1st Row y left-parenthesis t right-parenthesis equals script upper T left-brace x left-parenthesis t right-parenthesis right-brace equals integral Subscript negative infinity Superscript infinity Baseline x left-parenthesis tau right-parenthesis dot h left-parenthesis t minus tau right-parenthesis d tau equals integral Subscript negative infinity Superscript infinity Baseline x left-parenthesis t minus tau right-parenthesis dot h left-parenthesis tau right-parenthesis d tau comma EndLayout

which is called continuous‐time convolution. The convolution integral describes a filter operation and is written as y left-parenthesis t right-parenthesis equals x left-parenthesis t right-parenthesis asterisk h left-parenthesis t right-parenthesis. Causality of a system implies h left-parenthesis t right-parenthesis equals 0 for t less-than 0 and stability of a system is achieved if the integral of impulse response integral Subscript negative infinity Superscript infinity Baseline StartAbsoluteValue h left-parenthesis t right-parenthesis EndAbsoluteValue d t less-than upper M less-than infinity. A simple example for continuous‐time convolution is demonstrated in Fig. 1.3.

Schematic illustration of continuous-time convolution y(t)=∫x(τ)h(t-τ)dτ showing the folded version of the impulse response h(-τ) and shifted versions h(t-τ) for t=0,1,2.

Figure 1.3 Continuous‐time convolution y left-parenthesis t right-parenthesis equals integral x left-parenthesis tau right-parenthesis h left-parenthesis t minus tau right-parenthesis d tau showing the folded version of the impulse response h left-parenthesis negative tau right-parenthesis and shifted versions h left-parenthesis t minus tau right-parenthesis for t equals 0 comma 1 comma 2.

Using the complex exponential x left-parenthesis t right-parenthesis equals e Superscript j omega t as input with omega equals 2 pi f, the output is given by the convolution integral as

(1.6)StartLayout 1st Row 1st Column y left-parenthesis t right-parenthesis 2nd Column equals integral Subscript negative infinity Superscript infinity Baseline e Superscript j omega left-parenthesis t minus tau right-parenthesis Baseline dot h left-parenthesis tau right-parenthesis d tau equals e Superscript j omega t Baseline dot ModifyingBelow integral Subscript negative infinity Superscript infinity Baseline h left-parenthesis tau right-parenthesis dot e Superscript minus j omega tau Baseline d tau With presentation form for vertical right-brace Underscript upper H left-parenthesis j omega right-parenthesis right-arrow Fourier integral Endscripts EndLayout
(1.7)StartLayout 1st Row 1st Column Blank 2nd Column equals e Superscript j omega t Baseline dot upper H left-parenthesis j omega right-parenthesis equals e Superscript j omega t Baseline dot StartAbsoluteValue upper H left-parenthesis j omega right-parenthesis EndAbsoluteValue e Superscript j phi left-parenthesis omega right-parenthesis Baseline period EndLayout

This shows that for a exponential input x left-parenthesis t right-parenthesis, the output y left-parenthesis t right-parenthesis is again an exponential signal where the input signal is weighted by the complex number upper H left-parenthesis j omega right-parenthesis equals StartAbsoluteValue upper H left-parenthesis j omega right-parenthesis EndAbsoluteValue e Superscript j phi left-parenthesis omega right-parenthesis, which is the Fourier transform (integral) of the impulse response h left-parenthesis t right-parenthesis, and is also called the frequency response of a continuous‐time system given by

(1.8)StartLayout 1st Row upper H left-parenthesis j omega right-parenthesis equals integral Subscript negative infinity Superscript infinity Baseline h left-parenthesis t right-parenthesis dot e Superscript minus j omega t Baseline d t period EndLayout

From upper H left-parenthesis j omega right-parenthesis, we can compute the magnitude response

(1.9)StartAbsoluteValue upper H left-parenthesis j omega right-parenthesis EndAbsoluteValue equals StartRoot Re squared left-brace upper H left-parenthesis j omega right-parenthesis right-brace plus Im squared left-brace upper H left-parenthesis j omega right-parenthesis right-brace EndRoot

and the phase response

(1.10)phi left-parenthesis omega right-parenthesis equals arc tangent left-parenthesis StartFraction Im left-brace upper H left-parenthesis j omega right-parenthesis right-brace Over Re left-brace upper H left-parenthesis j omega right-parenthesis right-brace EndFraction right-parenthesis comma Re left-brace upper H left-parenthesis j omega right-parenthesis right-brace greater-than 0

of a continuous‐time system. For a given signal x left-parenthesis t right-parenthesis, we can give its continuous‐time Fourier transform as

(1.11)StartLayout 1st Row upper X left-parenthesis j omega right-parenthesis equals integral Subscript negative infinity Superscript infinity Baseline x left-parenthesis t right-parenthesis dot e Superscript minus j omega t Baseline d t logical-and upper X left-parenthesis f right-parenthesis equals integral Subscript negative infinity Superscript infinity Baseline x left-parenthesis t right-parenthesis dot e Superscript minus j Baseline 2 pi f t Baseline d t period EndLayout

The Fourier integral describes a spectral transform from time domain x left-parenthesis t right-parenthesis to frequency domain upper X left-parenthesis j omega right-parenthesis, which is called the Fourier spectrum or Fourier transform of x left-parenthesis t right-parenthesis. The inverse continuous‐time Fourier transform is given by

(1.12)StartLayout 1st Row x left-parenthesis t right-parenthesis equals StartFraction 1 Over 2 pi EndFraction integral Subscript negative infinity Superscript infinity Baseline upper X left-parenthesis j omega right-parenthesis dot e Superscript j omega t Baseline d omega logical-and x left-parenthesis t right-parenthesis equals integral Subscript negative infinity Superscript infinity Baseline upper X left-parenthesis f right-parenthesis dot e Superscript j Baseline 2 pi f t Baseline d f comma EndLayout

which takes the Fourier spectrum upper X left-parenthesis j omega right-parenthesis and reconstructs the input x left-parenthesis t right-parenthesis. In the following, useful Fourier transform pairs are listed in Eqs. (1.13)–(1.23). An important relation between the time domain x left-parenthesis t right-parenthesis right-arrow StartLayout 1st Row h left-parenthesis t right-parenthesis EndLayout right-arrow y left-parenthesis t right-parenthesis, using x left-parenthesis t right-parenthesis and h left-parenthesis t right-parenthesis giving y left-parenthesis t right-parenthesis, and frequency domain upper X left-parenthesis j omega right-parenthesis right-arrow StartLayout 1st Row upper H left-parenthesis j omega right-parenthesis EndLayout right-arrow upper Y left-parenthesis j omega right-parenthesis, using upper X left-parenthesis j omega right-parenthesis and upper H left-parenthesis j omega right-parenthesis giving upper Y left-parenthesis j omega right-parenthesis, shows that convolution in the time domain can be described by multiplication in the frequency domain.

Fourier Transform Pairs1

(1.14)StartLayout 1st Row 1st Column x left-parenthesis t minus t 0 right-parenthesis 2nd Column ring em-dash bullet 3rd Column upper X left-parenthesis f right-parenthesis dot e Superscript minus j Baseline 2 pi f t 0 EndLayout
(1.15)StartLayout 1st Row 1st Column x left-parenthesis t right-parenthesis dot e Superscript j Baseline 2 pi f Super Subscript c Superscript t 2nd Column ring em-dash bullet 3rd Column upper X left-parenthesis f minus f Subscript c Baseline right-parenthesis EndLayout
(1.16)StartLayout 1st Row 1st Column x left-parenthesis t right-parenthesis dot cosine left-parenthesis 2 pi f Subscript c Baseline t right-parenthesis 2nd Column ring em-dash bullet 3rd Column one half left-bracket upper X left-parenthesis f minus f Subscript c Baseline right-parenthesis plus upper X left-parenthesis f plus f Subscript c Baseline right-parenthesis right-bracket EndLayout
(1.17)StartLayout 1st Row 1st Column c 1 dot x 1 left-parenthesis t right-parenthesis plus c 2 dot x 2 left-parenthesis t right-parenthesis 2nd Column ring em-dash bullet 3rd Column c 1 dot upper X 1 left-parenthesis f right-parenthesis plus c 2 dot upper X 2 left-parenthesis f right-parenthesis EndLayout
(1.18)StartLayout 1st Row 1st Column x 1 left-parenthesis t right-parenthesis asterisk x 2 left-parenthesis t right-parenthesis 2nd Column ring em-dash bullet 3rd Column upper X 1 left-parenthesis f right-parenthesis dot upper X 2 left-parenthesis f right-parenthesis EndLayout
(1.19)StartLayout 1st Row 1st Column x left-parenthesis t right-parenthesis right-arrow StartEnclose box h left-parenthesis t right-parenthesis EndEnclose right-arrow y left-parenthesis t right-parenthesis 2nd Column ring em-dash bullet 3rd Column upper X left-parenthesis j omega right-parenthesis right-arrow StartEnclose box upper H left-parenthesis j omega right-parenthesis EndEnclose right-arrow upper Y left-parenthesis j omega right-parenthesis EndLayout
(1.20)StartLayout 1st Row 1st Column delta left-parenthesis t right-parenthesis 2nd Column ring em-dash bullet 3rd Column 1 EndLayout
(1.21)StartLayout 1st Row 1st Column delta left-parenthesis t minus t 0 right-parenthesis 2nd Column ring em-dash bullet 3rd Column e Superscript minus j Baseline 2 pi f t 0 EndLayout
(1.22)StartLayout 1st Row 1st Column rect left-parenthesis StartFraction t Over upper T EndFraction right-parenthesis 2nd Column ring em-dash bullet 3rd Column upper T dot sinc left-parenthesis upper T f right-parenthesis EndLayout

Fourier Transforms of Even and Causal Signals

Figure  1.4 shows the Fourier transforms of even and causal rect signals and Fig. 1.5 shows two even sinc signals and their Fourier transforms. The ripple in the passband is based on the truncated length of the sinc signal.

Schematic illustration of fourier transforms of an even and a causal rect signal. The small imaginary part of the lower left plot arises from a small asymmetry of the rect signal in the upper left plot.

Figure 1.4 Fourier transforms of an even and a causal rect signal. The small imaginary part of the lower left plot arises from a small asymmetry of the rect signal in the upper left plot.

Schematic illustration of fourier transforms of two even sinc signals.

Figure 1.5 Fourier transforms of two even sinc signals.

1.2 Continuous‐time Fourier Transform and Laplace Transform

The extension of the continuous‐time Fourier transform to the Laplace transform allows for the transform of signals and impulse responses where the Fourier transform does not converge but the Laplace transform converges for a given convergence region. This extension of the continuous‐time Fourier transform

(1.24)StartLayout 1st Row upper X left-parenthesis j omega right-parenthesis equals integral Subscript negative infinity Superscript infinity Baseline x left-parenthesis t right-parenthesis dot e Superscript minus j omega t Baseline d t EndLayout

is achieved by introducing a real part to the imaginary part according to a new complex variable StartLayout 1st Row s equals sigma plus j omega EndLayout, which then gives

(1.25)StartLayout 1st Row 1st Column upper X left-parenthesis sigma plus j omega right-parenthesis 2nd Column equals integral Subscript negative infinity Superscript infinity Baseline x left-parenthesis t right-parenthesis dot e Superscript minus left-parenthesis sigma plus j omega right-parenthesis t Baseline d t EndLayout
(1.26)StartLayout 1st Row 1st Column Blank 2nd Column equals integral Subscript negative infinity Superscript infinity Baseline x left-parenthesis t right-parenthesis dot e Superscript minus sigma t Baseline dot e Superscript minus j omega t Baseline d t EndLayout

and thus the Laplace transform

(1.27)StartLayout 1st Row upper X left-parenthesis s right-parenthesis equals integral Subscript negative infinity Superscript infinity Baseline x left-parenthesis t right-parenthesis dot e Superscript minus s t Baseline d t period EndLayout

The Laplace transform of signals often leads to a rational function upper X left-parenthesis s right-parenthesis equals StartFraction upper N left-parenthesis s right-parenthesis Over upper D left-parenthesis s right-parenthesis EndFraction with a numerator polynomial upper N left-parenthesis s right-parenthesis and a denominator polynomial upper D left-parenthesis s right-parenthesis in the variable s. The zeros of the numerator upper N left-parenthesis s right-parenthesis are called the zeros of upper X left-parenthesis s right-parenthesis and the zeros of upper D left-parenthesis s right-parenthesis are called the poles of upper X left-parenthesis s right-parenthesis. The rational function upper X left-parenthesis s right-parenthesis can be in given in polynomial, pole/zero, and partial expansion forms.

1.3 Sampling and Reconstruction

For digital signal processing, the sampling of x left-parenthesis t right-parenthesis with a sampling rate f Subscript upper S Baseline equals StartFraction 1 Over upper T Subscript upper S Baseline EndFraction and a sampling interval upper T Subscript upper S is performed, which leads to a sequence of numbers x left-parenthesis n right-parenthesis with time index n. According to the sampling theorem, the input signal x left-parenthesis t right-parenthesis must be band limited to f Subscript upper S Baseline slash 2. The sampling and the reconstruction of x left-parenthesis t right-parenthesis from the number sequence x left-parenthesis n right-parenthesis is achieved by the following sequence of operations: x left-parenthesis t right-parenthesis right-arrow StartLayout 1st Row upper A upper D upper C EndLayout right-arrow x left-parenthesis n right-parenthesis right-arrow StartLayout 1st Row upper D upper A upper C EndLayout right-arrow x left-parenthesis t right-parenthesis. Both operations are performed by an analog‐to‐digital converter (ADC) and a digital‐to‐analog converter (DAC). The converters can be considered as mixed continuous‐time and discrete‐time systems.

Sampling and quantization (analog‐to‐digital conversion) can be described by

(1.28)StartLayout 1st Row 1st Column x Subscript d Baseline left-parenthesis t right-parenthesis 2nd Column equals x left-parenthesis t right-parenthesis dot d left-parenthesis t right-parenthesis equals x left-parenthesis t right-parenthesis dot sigma-summation Underscript n equals negative infinity Overscript infinity Endscripts delta left-parenthesis t minus n upper T Subscript upper S Baseline right-parenthesis EndLayout
(1.29)StartLayout 1st Row 1st Column Blank 2nd Column equals sigma-summation Underscript n equals negative infinity Overscript infinity Endscripts x Subscript d Baseline left-parenthesis n upper T Subscript upper S Baseline right-parenthesis dot delta left-parenthesis t minus n upper T Subscript upper S Baseline right-parenthesis comma EndLayout
(1.30)StartLayout 1st Row 1st Column x left-parenthesis n right-parenthesis 2nd Column equals left-bracket x Subscript d Baseline left-parenthesis n upper T Subscript upper S Baseline right-parenthesis right-bracket Subscript upper Q Baseline comma EndLayout

where the input x left-parenthesis t right-parenthesis is sampled by multiplying it with a series of Dirac impulses d left-parenthesis t right-parenthesis equals sigma-summation Underscript n equals negative infinity Overscript infinity Endscripts delta left-parenthesis t minus n upper T Subscript upper S Baseline right-parenthesis giving the ideal sampled x Subscript d Baseline left-parenthesis t right-parenthesis and then quantization of the samples x Subscript d Baseline left-parenthesis n upper T Subscript upper S Baseline right-parenthesis to the sequence of numbers x left-parenthesis n right-parenthesis with a finite number representation. Figure 1.6 shows in the left column the time‐domain signals involved.

Schematic illustration of sampling and reconstruction ‐ Time-domain signals (left column) and corresponding Fourier spectra (right column).

Figure 1.6 Sampling and reconstruction – Time‐domain signals (left column) and corresponding Fourier spectra (right column).

Reconstruction (digital‐to‐analog conversion) of the continuous‐time x left-parenthesis t right-parenthesis from the sampled sequence x left-parenthesis n right-parenthesis can be written as a convolution operation given by

(1.31)x left-parenthesis t right-parenthesis equals sigma-summation Underscript n equals negative infinity Overscript infinity Endscripts x left-parenthesis n right-parenthesis dot sinc left-parenthesis f Subscript upper S Baseline left-parenthesis t minus n upper T Subscript upper S Baseline right-parenthesis right-parenthesis comma

which is shown in the bottom left plot of Fig. 1.6. The Fourier transforms of the individual signals for sampling are given by

(1.32)StartLayout 1st Row 1st Column x left-parenthesis t right-parenthesis 2nd Column ring em-dash bullet 3rd Column upper X left-parenthesis f right-parenthesis EndLayout
(1.33)StartLayout 1st Row 1st Column d left-parenthesis t right-parenthesis equals sigma-summation Underscript n equals negative infinity Overscript infinity Endscripts delta left-parenthesis t minus n upper T Subscript upper S Baseline right-parenthesis 2nd Column ring em-dash bullet 3rd Column upper D left-parenthesis f right-parenthesis equals StartFraction 1 Over upper T Subscript upper S Baseline EndFraction sigma-summation Underscript n equals negative infinity Overscript infinity Endscripts delta left-parenthesis f minus n f Subscript upper S Baseline right-parenthesis EndLayout
(1.34)StartLayout 1st Row 1st Column x Subscript d Baseline left-parenthesis t right-parenthesis equals x left-parenthesis t right-parenthesis dot d left-parenthesis t right-parenthesis 2nd Column ring em-dash bullet 3rd Column upper X Subscript d Baseline left-parenthesis f right-parenthesis equals upper X left-parenthesis f right-parenthesis asterisk upper D left-parenthesis f right-parenthesis EndLayout
(1.35)StartLayout 1st Row 1st Column Blank 2nd Column Blank 3rd Column equals StartFraction 1 Over upper T Subscript upper S Baseline EndFraction sigma-summation Underscript n equals negative infinity Overscript infinity Endscripts upper X left-parenthesis f minus n f Subscript upper S Baseline right-parenthesis EndLayout

and are shown in Fig. 1.6 (right column). Sampling leads to the periodic extension of the baseband spectrum at multiples of the sampling rate f Subscript upper S and the scaling by 1 slash upper T Subscript upper S. The reconstruction of

(1.36)StartLayout 1st Row 1st Column x left-parenthesis t right-parenthesis equals x Subscript d Baseline left-parenthesis t right-parenthesis asterisk h left-parenthesis t right-parenthesis 2nd Column ring em-dash bullet 3rd Column upper X left-parenthesis f right-parenthesis equals upper X Subscript d Baseline left-parenthesis f right-parenthesis dot upper H left-parenthesis f right-parenthesis EndLayout
(1.37)StartLayout 1st Row 1st Column Blank 2nd Column Blank 3rd Column equals upper X Subscript d Baseline left-parenthesis f right-parenthesis dot upper T Subscript upper S Baseline dot rect left-parenthesis StartFraction f Over f Subscript upper S Baseline EndFraction right-parenthesis EndLayout

is achieved by convolution with a system impulse response h left-parenthesis t right-parenthesis, which acts an ideal lowpass filter with cutoff frequency f Subscript upper S Baseline slash 2 and passband gain of upper T Subscript upper S to compensate for the scaling of the sampling operation, as shown in the bottom plots of Fig. 1.6.

1.4 Discrete‐time Signals and Convolution

With the discrete‐time input signal x left-parenthesis n right-parenthesis, we can describe an input/output relation in the discrete‐time domain, in signal flow graph form, as x left-parenthesis n right-parenthesis right-arrow StartLayout 1st Row h left-parenthesis n right-parenthesis EndLayout right-arrow y left-parenthesis n right-parenthesis equals script upper T left-brace x left-parenthesis n right-parenthesis right-brace, where the input is transformed into an output signal y left-parenthesis n right-parenthesis. Again we are using discrete‐time test signals represented in Fig. 1.7, such as the unit pulse

(1.38)delta left-parenthesis n right-parenthesis equals Start 2 By 3 Matrix 1st Row 1st Column 1 2nd Column for 3rd Column n equals 0 comma 2nd Row 1st Column 0 2nd Column for 3rd Column n not-equals 0 comma EndMatrix

and the step sequence

(1.39)epsilon left-parenthesis n right-parenthesis equals Start 2 By 3 Matrix 1st Row 1st Column 1 2nd Column for 3rd Column n greater-than-or-equal-to 0 comma 2nd Row 1st Column 0 2nd Column for 3rd Column n less-than 0 period EndMatrix

The lower row in Fig. 1.7 shows further discrete‐time signals which can be formulated using delayed unit pulses delta left-parenthesis n minus k right-parenthesis according to

Schematic illustration of discrete-time signals x1(n)=δ(n), x2(n)=δ(n-1), x3(t)=ε(n), x4(n)=δ(n+1)+δ(n)+δ(n-1), x5(n)=x4(n-1), and x6(n)=exp(-an)·ε(n).

Figure 1.7 Discrete‐time signals x 1 left-parenthesis n right-parenthesis equals delta left-parenthesis n right-parenthesis, x 2 left-parenthesis n right-parenthesis equals delta left-parenthesis n minus 1 right-parenthesis, x 3 left-parenthesis t right-parenthesis equals epsilon left-parenthesis n right-parenthesis, x 4 left-parenthesis n right-parenthesis equals delta left-parenthesis n plus 1 right-parenthesis plus delta left-parenthesis n right-parenthesis plus delta left-parenthesis n minus 1 right-parenthesis, x 5 left-parenthesis n right-parenthesis equals x 4 left-parenthesis n minus 1 right-parenthesis, and x 6 left-parenthesis n right-parenthesis equals exp left-parenthesis minus a n right-parenthesis dot epsilon left-parenthesis n right-parenthesis.

Schematic illustration of discrete-time convolution y(n)=Σkx(k)h(n-k) showing the folded version of the impulse response h(-k) and shifted versions h(n-k) for n=0,1,2.

Figure 1.8 Discrete‐time convolution y left-parenthesis n right-parenthesis equals sigma-summation Underscript k Endscripts x left-parenthesis k right-parenthesis h left-parenthesis n minus k right-parenthesis showing the folded version of the impulse response h left-parenthesis negative k right-parenthesis and shifted versions h left-parenthesis n minus k right-parenthesis for n equals 0 comma 1 comma 2.

and explicitly as, for example, x 6 left-parenthesis n right-parenthesis equals exp left-parenthesis minus a n right-parenthesis dot epsilon left-parenthesis n right-parenthesis. The discrete‐time system described by y left-parenthesis n right-parenthesis equals script upper T left-brace x left-parenthesis n right-parenthesis right-brace leads to the definition of the impulse response h left-parenthesis n right-parenthesis equals script upper T left-brace delta left-parenthesis n right-parenthesis right-brace of the discrete‐time system when the unit pulse delta left-parenthesis n right-parenthesis is used as an input signal x left-parenthesis n right-parenthesis. Using Eq. (1.40), we can derive the discrete‐time convolution as

(1.41)StartLayout 1st Row y left-parenthesis n right-parenthesis equals script upper T left-brace x left-parenthesis n right-parenthesis right-brace equals sigma-summation Underscript k equals negative infinity Overscript infinity Endscripts x left-parenthesis k right-parenthesis dot h left-parenthesis n minus k right-parenthesis equals sigma-summation Underscript k equals negative infinity Overscript infinity Endscripts x left-parenthesis n minus k right-parenthesis dot h left-parenthesis n right-parenthesis period EndLayout

The convolution sum describes a digital filter operation and is written as y left-parenthesis n right-parenthesis equals x left-parenthesis n right-parenthesis asterisk h left-parenthesis n right-parenthesis. The discrete‐time convolution is illustrated in Fig. 1.8. Causality of a discrete‐time system implies h left-parenthesis n right-parenthesis equals 0 for n less-than 0 and stability of a discrete‐time system is achieved if sigma-summation Underscript n Endscripts StartAbsoluteValue h left-parenthesis n right-parenthesis EndAbsoluteValue less-than upper M less-than infinity.

Using the complex exponential x left-parenthesis n right-parenthesis equals e Superscript j normal upper Omega n as input with normal upper Omega equals 2 pi StartFraction f Over f Subscript upper S Baseline EndFraction, the output is given by the convolution sum as

StartLayout 1st Row 1st Column y left-parenthesis n right-parenthesis 2nd Column equals 3rd Column sigma-summation Underscript k equals negative infinity Overscript infinity Endscripts e Superscript j normal upper Omega left-parenthesis n minus k right-parenthesis Baseline dot h left-parenthesis k right-parenthesis equals e Superscript j normal upper Omega n Baseline dot ModifyingBelow sigma-summation Underscript k Endscripts h left-parenthesis k right-parenthesis dot e Superscript minus j normal upper Omega k Baseline With presentation form for vertical right-brace Underscript upper H left-parenthesis e Superscript j normal upper Omega right-parenthesis Baseline Endscripts 2nd Row 1st Column Blank 2nd Column equals 3rd Column e Superscript j normal upper Omega n Baseline dot upper H left-parenthesis e Superscript j normal upper Omega right-parenthesis Baseline right-parenthesis equals e Superscript j normal upper Omega n Baseline dot vertical-bar upper H left-parenthesis e Superscript j normal upper Omega n right-parenthesis Baseline vertical-bar e Superscript j phi left-parenthesis normal upper Omega right-parenthesis Baseline period EndLayout

This shows that for an exponential input x left-parenthesis n right-parenthesis, the output y left-parenthesis n right-parenthesis is again an exponential signal where the input signal is weighted by the complex number upper H left-parenthesis e Superscript j normal upper Omega Baseline right-parenthesis equals StartAbsoluteValue upper H left-parenthesis e Superscript j normal upper Omega Baseline right-parenthesis EndAbsoluteValue e Superscript j phi left-parenthesis normal upper Omega right-parenthesis, which is the discrete‐time Fourier transform of the impulse response h left-parenthesis n right-parenthesis, and is also called the frequency response

(1.42)StartLayout 1st Row upper H left-parenthesis e Superscript j normal upper Omega Baseline right-parenthesis equals sigma-summation Underscript n equals negative infinity Overscript infinity Endscripts h left-parenthesis n right-parenthesis dot e Superscript minus j normal upper Omega n EndLayout

of a discrete‐time system. From upper H left-parenthesis e Superscript j normal upper Omega Baseline right-parenthesis, we can compute the magnitude response

(1.43)StartAbsoluteValue upper H left-parenthesis e Superscript j normal upper Omega Baseline right-parenthesis EndAbsoluteValue equals StartRoot Re squared left-brace upper H left-parenthesis e Superscript j normal upper Omega Baseline right-parenthesis right-brace plus Im squared left-brace upper H left-parenthesis e Superscript j normal upper Omega Baseline right-parenthesis right-brace EndRoot

and the phase response

(1.44)phi left-parenthesis normal upper Omega right-parenthesis equals arc tangent left-parenthesis StartFraction Im left-brace upper H left-parenthesis e Superscript j normal upper Omega Baseline right-parenthesis right-brace Over Re left-brace upper H left-parenthesis e Superscript j normal upper Omega Baseline right-parenthesis right-brace EndFraction right-parenthesis comma Re left-brace upper H left-parenthesis e Superscript j normal upper Omega Baseline right-parenthesis right-brace greater-than 0

of a discrete‐time system. For a given signal x left-parenthesis n right-parenthesis, we can give its discrete‐time Fourier transform as

(1.45)StartLayout 1st Row upper X left-parenthesis e Superscript j normal upper Omega Baseline right-parenthesis equals sigma-summation Underscript n equals negative infinity Overscript infinity Endscripts x left-parenthesis n right-parenthesis dot e Superscript minus j normal upper Omega n Baseline period EndLayout

The discrete‐time Fourier Transform describes a spectral transform from the discrete‐time domain x left-parenthesis n right-parenthesis to the frequency domain upper X left-parenthesis e Superscript j normal upper Omega Baseline right-parenthesis comma which is called the Fourier spectrum or Fourier transform of x left-parenthesis n right-parenthesis. The inverse discrete‐time Fourier transform is given by

(1.46)StartLayout 1st Row x left-parenthesis n right-parenthesis equals StartFraction 1 Over 2 pi EndFraction integral Subscript negative pi Superscript pi Baseline upper X left-parenthesis e Superscript j normal upper Omega Baseline right-parenthesis dot dot e Superscript j normal upper Omega n Baseline d normal upper Omega comma EndLayout

which takes the discrete‐time Fourier spectrum upper X left-parenthesis e Superscript j normal upper Omega Baseline right-parenthesis and reconstructs the input x left-parenthesis n right-parenthesis. In the following, useful discrete‐time Fourier transform pairs are listed in Eqs. (1.47)–(1.56). An important relation between the time domain x left-parenthesis n right-parenthesis right-arrow StartLayout 1st Row h left-parenthesis n right-parenthesis EndLayout right-arrow y left-parenthesis n right-parenthesis, using x left-parenthesis n right-parenthesis and h left-parenthesis n right-parenthesis giving y left-parenthesis n right-parenthesis, and the frequency domain upper X left-parenthesis j omega right-parenthesis right-arrow StartLayout 1st Row upper H left-parenthesis j omega right-parenthesis EndLayout right-arrow upper Y left-parenthesis e Superscript j normal upper Omega Baseline right-parenthesis, using upper X left-parenthesis e Superscript j normal upper Omega Baseline right-parenthesis and upper H left-parenthesis e Superscript j normal upper Omega Baseline right-parenthesis giving upper Y left-parenthesis e Superscript j normal upper Omega Super Superscript Superscript Baseline right-parenthesis, shows that convolution in the time domain can be described by multiplication in the frequency domain.

Discrete‐time Fourier Transform Pairs

(1.48)StartLayout 1st Row 1st Column x left-parenthesis n minus m right-parenthesis 2nd Column ring em-dash bullet 3rd Column upper X left-parenthesis e Superscript j normal upper Omega Baseline right-parenthesis e Superscript minus j m normal upper Omega EndLayout
(1.49)StartLayout 1st Row 1st Column x left-parenthesis n right-parenthesis e Superscript j normal upper Omega 0 n 2nd Column ring em-dash bullet 3rd Column upper X left-parenthesis e Superscript j left-parenthesis normal upper Omega minus normal upper Omega 0 right-parenthesis Baseline right-parenthesis EndLayout
(1.50)StartLayout 1st Row 1st Column x 1 left-parenthesis n right-parenthesis asterisk x 2 left-parenthesis n right-parenthesis 2nd Column ring em-dash bullet 3rd Column upper X 1 left-parenthesis e Superscript j normal upper Omega Baseline right-parenthesis dot upper X 2 left-parenthesis e Superscript j normal upper Omega Baseline right-parenthesis EndLayout
(1.51)StartLayout 1st Row 1st Column x left-parenthesis n right-parenthesis right-arrow StartEnclose box h left-parenthesis n right-parenthesis EndEnclose right-arrow y left-parenthesis n right-parenthesis 2nd Column ring em-dash bullet 3rd Column upper X left-parenthesis e Superscript j normal upper Omega Baseline right-parenthesis right-arrow StartEnclose box upper H left-parenthesis e Superscript j normal upper Omega Baseline right-parenthesis EndEnclose right-arrow upper Y left-parenthesis e Superscript j normal upper Omega Baseline right-parenthesis EndLayout
(1.52)StartLayout 1st Row 1st Column delta left-parenthesis n right-parenthesis 2nd Column ring em-dash bullet 3rd Column 1 EndLayout
(1.53)StartLayout 1st Row 1st Column delta left-parenthesis n minus m right-parenthesis 2nd Column ring em-dash bullet 3rd Column e Superscript minus j m normal upper Omega EndLayout
(1.54)StartLayout 1st Row 1st Column delta left-parenthesis n right-parenthesis plus delta left-parenthesis n minus 1 right-parenthesis 2nd Column ring em-dash bullet 3rd Column 1 plus e Superscript minus j normal upper Omega Baseline equals 1 plus cosine normal upper Omega minus j sine normal upper Omega EndLayout
(1.55)StartLayout 1st Row 1st Column sigma-summation Underscript k equals 0 Overscript upper N minus 1 Endscripts delta left-parenthesis n minus k right-parenthesis 2nd Column ring em-dash bullet 3rd Column sigma-summation Underscript k equals 0 Overscript upper N minus 1 Endscripts e Superscript minus j k normal upper Omega EndLayout

1.5 Discrete‐time Fourier Transform and Z‐Transform

The extension of the discrete‐time Fourier transform to the Z‐transform allows for the transform of signals and impulse responses where the discrete‐time Fourier transform does not converge but the Z‐transform converges for a given convergence region. This extension of the discrete‐time Fourier transform

(1.57)StartLayout 1st Row upper X left-parenthesis e Superscript j normal upper Omega Baseline right-parenthesis equals sigma-summation Underscript n equals negative infinity Overscript infinity Endscripts x left-parenthesis n right-parenthesis dot e Superscript minus j normal upper Omega n EndLayout

is achieved by introducing a radius r to the complex exponential e Superscript j normal upper Omega according to a new complex variable StartLayout 1st Row z equals r e Superscript j normal upper Omega EndLayout, which then gives

(1.58)StartLayout 1st Row 1st Column upper X left-parenthesis r e Superscript j normal upper Omega Baseline right-parenthesis 2nd Column equals sigma-summation Underscript n equals negative infinity Overscript infinity Endscripts x left-parenthesis n right-parenthesis dot left-parenthesis r e Superscript j normal upper Omega Baseline right-parenthesis Superscript negative n EndLayout
(1.59)StartLayout 1st Row 1st Column Blank 2nd Column equals sigma-summation Underscript n equals negative infinity Overscript infinity Endscripts x left-parenthesis n right-parenthesis dot r Superscript negative n Baseline dot e Superscript minus j normal upper Omega n EndLayout

and thus the Z‐transform

(1.60)StartLayout 1st Row upper X left-parenthesis z right-parenthesis equals sigma-summation Underscript n equals negative infinity Overscript infinity Endscripts x left-parenthesis n right-parenthesis dot z Superscript negative n Baseline period EndLayout

The Z‐transform of many signals leads to a rational function upper X left-parenthesis z right-parenthesis equals StartFraction upper N left-parenthesis z right-parenthesis Over upper D left-parenthesis z right-parenthesis EndFraction, with a numerator polynomial upper N left-parenthesis z right-parenthesis and a denominator polynomial upper D left-parenthesis z right-parenthesis in the variable z. The zeros of the numerator upper N left-parenthesis z right-parenthesis are called the zeros of upper X left-parenthesis z right-parenthesis and the zeros of upper D left-parenthesis z right-parenthesis are called the poles of upper X left-parenthesis z right-parenthesis. The rational function upper X left-parenthesis z right-parenthesis can be given in polynomial, pole/zero, and partial expansion forms.

1.6 Discrete Fourier Transform

To reduce the the length of the input signal x left-parenthesis n right-parenthesis to upper N samples and to compute the Fourier spectrum only at a finite number of upper N frequency samples, we can discretize the unit circle normal upper Omega Subscript k Baseline equals StartFraction 2 pi Over upper N EndFraction k at upper N frequency samples, and using upper N samples, x left-parenthesis n right-parenthesis gives

(1.61)upper X left-parenthesis e Superscript j normal upper Omega Super Subscript k Superscript Baseline right-parenthesis equals sigma-summation Underscript n equals 0 Overscript upper N minus 1 Endscripts x left-parenthesis n right-parenthesis e Superscript minus j normal upper Omega Super Subscript k Superscript n Baseline comma normal upper Omega Subscript k Baseline equals StartFraction 2 pi Over upper N EndFraction k comma k equals 0 comma 1 comma ellipsis comma upper N minus 1

and the discrete Fourier transform (DFT)

(1.62)StartEnclose box StartLayout 1st Row upper X left-parenthesis k right-parenthesis equals sigma-summation Underscript n equals 0 Overscript upper N minus 1 Endscripts x left-parenthesis n right-parenthesis e Superscript minus j StartFraction 2 pi Over upper N EndFraction k n Baseline 2nd Row k equals 0 comma 1 comma ellipsis comma upper N minus 1 EndLayout EndEnclose

and the inverse discrete Fourier transform (IDFT)

(1.63)StartEnclose box StartLayout 1st Row x left-parenthesis n right-parenthesis equals StartFraction 1 Over upper N EndFraction sigma-summation Underscript k equals 0 Overscript upper N minus 1 Endscripts upper X left-parenthesis k right-parenthesis e Superscript j StartFraction 2 pi Over upper N EndFraction k n Baseline 2nd Row n equals 0 comma 1 comma ellipsis comma upper N minus 1 period EndLayout EndEnclose

The DFT of a causal audio signal is shown in Fig. 1.9.

Schematic illustration of fourier transform of an audio signal x(n) (top plot) and its magnitude spectrum |X(f)| in dB versus logarithmic (middle plot) and linear frequency axis (bottom plot).

Figure 1.9 Fourier transform of an audio signal x left-parenthesis n right-parenthesis (top plot) and its magnitude spectrum StartAbsoluteValue upper X left-parenthesis f right-parenthesis EndAbsoluteValue in dB versus logarithmic (middle plot) and linear frequency axis (bottom plot).

1.7 FIR and IIR Filters

For causal signals x left-parenthesis n right-parenthesis and causal impulse responses h left-parenthesis n right-parenthesis, the convolution sum is given by y left-parenthesis n right-parenthesis equals sigma-summation Underscript k equals 0 Overscript infinity Endscripts h left-parenthesis k right-parenthesis dot x left-parenthesis n minus k right-parenthesis equals sigma-summation Underscript k equals 0 Overscript infinity Endscripts x left-parenthesis k right-parenthesis dot h left-parenthesis n minus k right-parenthesis. A further simplification is possible if the impulse response is decaying very rapidly and can be truncated in length after upper N samples, which then leads to a finite impulse response (FIR) filter with upper N taps (Matlab file y=filter(b,1,x)) and the discrete‐time convolution

which is also called a difference equation. The difference equation can be represented by an FIR signal flow graph (block diagram), as shown in Fig. 1.10. The coefficients b left-parenthesis k right-parenthesis correspond to the impulse response h left-parenthesis k right-parenthesis. Deriving the Z‐transform of Eq. (1.64) gives

Schematic illustration of block diagram of FIR filter.

Figure 1.10 Block diagram of FIR filter.

(1.65)upper Y left-parenthesis z right-parenthesis equals sigma-summation Underscript k equals 0 Overscript upper N minus 1 Endscripts b left-parenthesis k right-parenthesis dot z Superscript negative k Baseline dot upper X left-parenthesis z right-parenthesis comma

from which we can derive the system transfer function upper H left-parenthesis z right-parenthesis equals StartFraction upper Y left-parenthesis z right-parenthesis Over upper X left-parenthesis z right-parenthesis EndFraction, which gives

(1.66)upper H left-parenthesis z right-parenthesis equals sigma-summation Underscript k equals 0 Overscript upper N minus 1 Endscripts b left-parenthesis k right-parenthesis dot z Superscript negative k Baseline equals StartFraction sigma-summation Underscript k equals 0 Overscript upper N minus 1 Endscripts b left-parenthesis k right-parenthesis dot z Superscript upper N minus 1 minus k Baseline Over z Superscript upper N minus 1 Baseline EndFraction period

The frequency response of the FIR filter (Matlab file freqz(b,1)) can be derived by taking the discrete‐time Fourier transform of the impulse response or evaluating the system transfer function on the unit circle by replacing z right-arrow e Superscript j normal upper Omega, which gives

(1.67)upper H Subscript FIR Baseline left-parenthesis e Superscript j normal upper Omega Baseline right-parenthesis equals sigma-summation Underscript k equals 0 Overscript upper N minus 1 Endscripts b left-parenthesis k right-parenthesis dot e Superscript minus j normal upper Omega k Baseline comma normal upper Omega equals 2 pi StartFraction f Over f Subscript upper S Baseline EndFraction period

Figure 1.11 shows a symmetric FIR impulse response with five taps, the magnitude response, phase response, and the pole/zero plot.

If the impulse response is decaying infinitely long, we have an infinite impulse response (IIR) filter of order upper N (Matlab file y=filter(b,[1 a],x)) which is dependent on its input x left-parenthesis n right-parenthesis and upper N delayed versions x left-parenthesis n minus k right-parenthesis, weighted by the coefficients b left-parenthesis k right-parenthesis, and upper N delayed versions y left-parenthesis n minus k right-parenthesis of the output y left-parenthesis n right-parenthesis, weighted by the coefficients a left-parenthesis k right-parenthesis according to

which is also called a difference equation. The difference equation can be represented by an IIR signal flow graph (block diagram), as shown in Fig. 1.12. Performing the Z‐transform of the recursive difference equation in Eq. (1.68) gives

(1.69)upper Y left-parenthesis z right-parenthesis equals sigma-summation Underscript k equals 0 Overscript upper N Endscripts b left-parenthesis k right-parenthesis dot z Superscript negative k Baseline dot upper X left-parenthesis z right-parenthesis minus sigma-summation Underscript k equals 1 Overscript upper N Endscripts a left-parenthesis k right-parenthesis dot z Superscript negative k Baseline dot upper Y left-parenthesis z right-parenthesis comma

from which we can derive the system transfer function upper H left-parenthesis z right-parenthesis equals StartFraction upper Y left-parenthesis z right-parenthesis Over upper X left-parenthesis z right-parenthesis EndFraction by deriving

(1.70)upper H left-parenthesis z right-parenthesis equals StartFraction sigma-summation Underscript k equals 0 Overscript upper N Endscripts b left-parenthesis k right-parenthesis dot z Superscript negative k Baseline Over 1 plus sigma-summation Underscript k equals 1 Overscript upper N Endscripts a left-parenthesis k right-parenthesis dot z Superscript negative k Baseline EndFraction period
Schematic illustration of FIR filter impulse response, magnitude response, phase response, and pole/zero plot.

Figure 1.11 FIR filter impulse response, magnitude response, phase response, and pole/zero plot.

Schematic illustration of block diagram of an IIR filter.

Figure 1.12 Block diagram of an IIR filter.

Typically, upper N equals 1 or upper N equals 2, and for higher order, we can use a cascade of first‐ and second‐order sub‐filters. Figure 1.13 shows a signal flow graph for an IIR filter cascade. The frequency response of the IIR filter (freqz(b,[1 a])) can be derived by evaluating the system transfer function on the unit circle by replacing z right-arrow e Superscript j normal upper Omega, which gives the frequency response of an IIR filter of order upper N (freqz(b,[1 a])) according to

Schematic illustration of IIR filter cascade.

Figure 1.13 IIR filter cascade.

(1.71)upper H Subscript IIR Baseline left-parenthesis e Superscript j normal upper Omega Baseline right-parenthesis equals StartFraction sigma-summation Underscript k equals 0 Overscript upper N Endscripts b left-parenthesis k right-parenthesis dot e Superscript minus j normal upper Omega k Baseline Over 1 plus sigma-summation Underscript k equals 1 Overscript upper N Endscripts a left-parenthesis k right-parenthesis dot e Superscript minus j normal upper Omega k Baseline EndFraction comma normal upper Omega equals 2 pi StartFraction f Over f Subscript upper S Baseline EndFraction period

Figure 1.14 shows an IIR impulse response with infinite decay, the magnitude response, phase response, and the pole/zero plot.

Some specific FIR filters are the upper N‐tap moving average filter,

(1.72)h Subscript MA Baseline left-parenthesis n right-parenthesis equals StartFraction 1 Over upper N EndFraction sigma-summation Underscript k equals 0 Overscript upper N minus 1 Endscripts delta left-parenthesis n minus k right-parenthesis comma

the triangular filter,

(1.73)h Subscript TRI Baseline left-parenthesis n right-parenthesis equals h Subscript MA Baseline left-parenthesis n right-parenthesis asterisk h Subscript MA Baseline left-parenthesis n right-parenthesis comma

and the equi‐ripple Parks–McClellan filter,

(1.74)h Subscript PM Baseline left-parenthesis n right-parenthesis equals sigma-summation Underscript k equals 0 Overscript upper N minus 1 Endscripts h left-parenthesis k right-parenthesis delta left-parenthesis n minus k right-parenthesis comma

where the impulse response is computed based on the Parks–McClellan [Opp14] design approach. Complementary filters, according to

(1.75)h Subscript normal upper C Baseline left-parenthesis n right-parenthesis equals delta left-parenthesis n minus StartFraction upper N minus 1 Over 2 EndFraction right-parenthesis minus sigma-summation Underscript k equals 0 Overscript upper N minus 1 Endscripts h left-parenthesis k right-parenthesis delta left-parenthesis n minus k right-parenthesis comma

allow for the use of a lowpass FIR filter of odd length upper N to perform lowpass‐to‐highpass and bandpass‐to‐bandstop transformations. Some frequency responses of these FIR filters are shown in Fig. 1.15.

Some simple but effective first‐ and second‐order IIR filters for lowpass (LP), highpass (HP), and bandpass (BP) filtering are given by

(1.76)StartLayout 1st Row 1st Column upper H Subscript LP Baseline left-parenthesis z right-parenthesis 2nd Column equals StartFraction 1 minus a Over 2 EndFraction StartFraction 1 plus z Superscript negative 1 Baseline Over 1 minus a z Superscript negative 1 Baseline EndFraction comma EndLayout
Schematic illustration of IIR filter and impulse response, magnitude response, phase response, and pole/zero plot.

Figure 1.14 IIR filter and impulse response, magnitude response, phase response, and pole/zero plot.

Schematic illustration of frequency responses and impulse responses of a moving average FIR and a Parks-McClellan FIR filter.

Figure 1.15 Frequency responses and impulse responses of a moving average FIR and a Parks–McClellan FIR filter. In the two frequency response plots, a complementary frequency response is also shown.

(1.77)StartLayout 1st Row 1st Column a 2nd Column equals StartFraction 1 minus sine left-parenthesis 2 pi f Subscript c Baseline slash f Subscript upper S Baseline right-parenthesis Over cosine left-parenthesis 2 pi f Subscript c Baseline slash f Subscript upper S Baseline right-parenthesis EndFraction period EndLayout
(1.78)StartLayout 1st Row 1st Column upper H Subscript HP Baseline left-parenthesis z right-parenthesis 2nd Column equals StartFraction 1 plus a Over 2 EndFraction StartFraction 1 minus z Superscript negative 1 Baseline Over 1 minus a z Superscript negative 1 Baseline EndFraction comma EndLayout
(1.79)StartLayout 1st Row 1st Column a 2nd Column equals StartFraction 1 minus sine left-parenthesis 2 pi f Subscript c Baseline slash f Subscript upper S Baseline right-parenthesis Over cosine left-parenthesis 2 pi f Subscript c Baseline slash f Subscript upper S Baseline right-parenthesis EndFraction period EndLayout
(1.80)StartLayout 1st Row 1st Column upper H Subscript BP Baseline left-parenthesis z right-parenthesis 2nd Column equals StartFraction 1 minus a Over 2 EndFraction StartFraction 1 minus z Superscript negative 2 Baseline Over 1 minus b left-parenthesis 1 plus a right-parenthesis z Superscript negative 1 Baseline plus a z Superscript negative 2 Baseline EndFraction comma EndLayout

They all have one (LP, HP) or two coefficients (BP) for controlling their cutoff frequency f Subscript c in Hz (negative 3‐dB magnitude of LP or HP frequency response) and the BP bandwidth f Subscript b in Hz (lower and higher than negative 3‐dB magnitude of BP frequency response). Their frequency responses are shown in Fig. 1.16. These simple first‐ and second‐order IIR filters (LP, HP, and BP) can be further implemented using first‐ and second‐order allpass filters upper H Subscript AP Sub Subscript 1 Baseline left-parenthesis z right-parenthesis and upper H Subscript AP Sub Subscript 2 Baseline left-parenthesis z right-parenthesis, as shown in the sequence of system transfer functions given by

Schematic illustration of frequency response of IIR filter.

Figure 1.16 Frequency response of IIR filter.

where the coefficients a and b are given by Eq. (1.81) and Eq. (1.82), respectively. The lowpass transfer function in Eq. (1.85) is an additive parallel connection of direct path and a first‐order allpass of Eq. (1.83). The highpass transfer function in Eq. (1.86) is a subtractive parallel connection of direct path and a first‐order allpass of Eq. (1.83). Finally, the bandpass transfer function in Eq. (1.87) is a subtractive parallel connection of direct path and a first‐order allpass of Eq. (1.84).

1.8 Adaptive Filters

Adaptive filters change their filter characteristic according to a predefined error criterion. A generic structure is shown in Fig. 1.17 where a desired signal d left-parenthesis n right-parenthesis is approximated by a reference signal x left-parenthesis n right-parenthesis passing through an adaptive filter giving an output signal y left-parenthesis n right-parenthesis, which should be made close to d left-parenthesis n right-parenthesis such that the error signal e left-parenthesis n right-parenthesis between the desired signal d left-parenthesis n right-parenthesis and the output signal y left-parenthesis n right-parenthesis gets smaller with time. The coefficients of the adaptive filter are derived by minimizing the error energy. Based on the generic structure shown in Fig. 1.17, special adaptive filter approaches for system identification, inverse filtering, echo cancellation, and linear prediction can be achieved. We will show how to perform linear prediction as an adaptive FIR filter technique and derive the adaption of the filter coefficients by the autocorrelation method and the least‐mean‐square (LMS) method.

Schematic illustration of adaptive signal approximation.

Figure 1.17 Adaptive signal approximation.

Adaptive Linear Prediction using the Autocorrelation Method

For the task of adaptive linear prediction, the generic structure is simplified because the desired signal d left-parenthesis n right-parenthesis is equal to the input x left-parenthesis n right-parenthesis, which leads to the signal flow graph of linear prediction shown in Fig. 1.18. The adaptive filter is, in that case, an FIR filter with p coefficients. Linear prediction computes an estimate

Schematic illustration of linear prediction.

Figure 1.18 Linear prediction.

(1.88)ModifyingAbove x With caret left-parenthesis n right-parenthesis equals sigma-summation Underscript k equals 1 Overscript p Endscripts b left-parenthesis k right-parenthesis x left-parenthesis n minus k right-parenthesis equals sigma-summation Underscript k equals 1 Overscript p Endscripts b Subscript k Baseline x left-parenthesis n minus k right-parenthesis

of the actual sample x left-parenthesis n right-parenthesis by a linear combination of past weighted input samples. Here p is the prediction order and b Subscript k are the prediction coefficients. The difference between x left-parenthesis n right-parenthesis and its prediction ModifyingAbove x With caret left-parenthesis n right-parenthesis is called the prediction error and is given by

(1.89)e left-parenthesis n right-parenthesis equals x left-parenthesis n right-parenthesis minus ModifyingAbove x With caret left-parenthesis n right-parenthesis equals x left-parenthesis n right-parenthesis minus sigma-summation Underscript k equals 1 Overscript p Endscripts b Subscript k Baseline x left-parenthesis n minus k right-parenthesis period

The filter coefficients b Subscript k are computed by minimizing a cost function

(1.90)upper J equals upper E left-brace e squared left-parenthesis n right-parenthesis right-brace

and thus minimizing the quadratic error2. The partial derivatives of the cost function with respect to the filter coefficients b Subscript k (for k equals 1 comma ellipsis p) lead to

(1.91)StartLayout 1st Row 1st Column StartFraction partial-differential upper J Over partial-differential b Subscript k Baseline EndFraction 2nd Column equals 2 upper E left-brace e left-parenthesis n right-parenthesis dot StartFraction partial-differential e left-parenthesis n right-parenthesis Over partial-differential b Subscript k Baseline EndFraction right-brace equals minus 2 upper E left-brace e left-parenthesis n right-parenthesis x left-parenthesis n minus k right-parenthesis right-brace EndLayout
(1.92)StartLayout 1st Row 1st Column Blank 2nd Column equals minus 2 upper E left-brace left-bracket x left-parenthesis n right-parenthesis minus sigma-summation Underscript i equals 1 Overscript p Endscripts b Subscript i Baseline x left-parenthesis n minus i right-parenthesis right-bracket x left-parenthesis n minus k right-parenthesis right-brace EndLayout
(1.93)StartLayout 1st Row 1st Column Blank 2nd Column equals minus 2 upper E left-brace x left-parenthesis n right-parenthesis x left-parenthesis n minus k right-parenthesis right-brace plus 2 sigma-summation Underscript i equals 1 Overscript p Endscripts b Subscript i Baseline upper E left-brace x left-parenthesis n minus i right-parenthesis x left-parenthesis n minus k right-parenthesis right-brace period EndLayout

Computing the filter coefficients b Subscript k by setting the partial derivative to zero gives, for k equals 1 comma ellipsis comma p,

(1.94)StartFraction partial-differential upper J Over partial-differential b Subscript k Baseline EndFraction equals 0

By using the autocorrelation sequence

(1.96)r Subscript x x Baseline left-parenthesis k right-parenthesis equals upper E left-brace x left-parenthesis n right-parenthesis x left-parenthesis n minus k right-parenthesis right-brace equals sigma-summation Underscript n equals negative infinity Overscript infinity Endscripts x left-parenthesis n right-parenthesis x left-parenthesis n minus k right-parenthesis

and the properties

(1.97)StartLayout 1st Row 1st Column r Subscript x x Baseline left-parenthesis k minus i right-parenthesis 2nd Column equals upper E left-brace x left-parenthesis n right-parenthesis x left-parenthesis n minus left-parenthesis k minus i right-parenthesis right-parenthesis right-brace 2nd Row 1st Column Blank 2nd Column equals upper E left-brace x left-parenthesis n minus i right-parenthesis x left-parenthesis n minus k right-parenthesis right-parenthesis right-brace EndLayout
(1.98)and r Subscript x x Baseline left-parenthesis k right-parenthesis equals r Subscript x x Baseline left-parenthesis negative k right-parenthesis left-parenthesis even sequence right-parenthesis

leads to the set of equations (1.95) in matrix form as

(1.99)Start 5 By 5 Matrix 1st Row 1st Column r Subscript x x Baseline left-parenthesis 0 right-parenthesis 2nd Column r Subscript x x Baseline left-parenthesis 1 right-parenthesis 3rd Column r Subscript x x Baseline left-parenthesis 2 right-parenthesis 4th Column midline-horizontal-ellipsis 5th Column r Subscript x x Baseline left-parenthesis p minus 1 right-parenthesis 2nd Row 1st Column r Subscript x x Baseline left-parenthesis 1 right-parenthesis 2nd Column r Subscript x x Baseline left-parenthesis 0 right-parenthesis 3rd Column r Subscript x x Baseline left-parenthesis 1 right-parenthesis 4th Column midline-horizontal-ellipsis 5th Column r Subscript x x Baseline left-parenthesis p minus 2 right-parenthesis 3rd Row 1st Column r Subscript x x Baseline left-parenthesis 2 right-parenthesis 2nd Column r Subscript x x Baseline left-parenthesis 1 right-parenthesis 3rd Column r Subscript x x Baseline left-parenthesis 0 right-parenthesis 4th Column down-right-diagonal-ellipsis 5th Column vertical-ellipsis 4th Row 1st Column vertical-ellipsis 2nd Column vertical-ellipsis 3rd Column down-right-diagonal-ellipsis 4th Column down-right-diagonal-ellipsis 5th Column r Subscript x x Baseline left-parenthesis 1 right-parenthesis 5th Row 1st Column r Subscript x x Baseline left-parenthesis p minus 1 right-parenthesis 2nd Column r Subscript x x Baseline left-parenthesis p minus 2 right-parenthesis 3rd Column midline-horizontal-ellipsis 4th Column r Subscript x x Baseline left-parenthesis 1 right-parenthesis 5th Column r Subscript x x Baseline left-parenthesis 0 right-parenthesis EndMatrix Start 4 By 1 Matrix 1st Row b 1 2nd Row b 2 3rd Row vertical-ellipsis 4th Row b Subscript p Baseline EndMatrix equals Start 4 By 1 Matrix 1st Row r Subscript x x Baseline left-parenthesis 1 right-parenthesis 2nd Row r Subscript x x Baseline left-parenthesis 2 right-parenthesis 3rd Row vertical-ellipsis 4th Row r Subscript x x Baseline left-parenthesis p right-parenthesis EndMatrix period

These equations are called Wiener–Hopf equations or normal equations. The so‐called autocorrelation matrix bold upper R is symmetric and has identical values on each diagonal. It is a Toeplitz matrix and the set of equations can be solved efficiently by the Levinson–Durbin recursion. The described procedure is called the autocorrelation method for updating the prediction coefficients.

Adaptive Linear Prediction using the LMS Method

In this method, a recursive algorithm for minimizing a simplified cost function modifying above upper J with caret is applied by minimizing the LMS error. All filter coefficients will be updated every sampling cycle based on previous values. This recursive approach for the filter coefficients uses the gradient descent formula

(1.100)b Subscript k Baseline left-parenthesis n plus 1 right-parenthesis equals b Subscript k Baseline left-parenthesis n right-parenthesis minus one half mu left-parenthesis n right-parenthesis StartFraction partial-differential upper J Over partial-differential b Subscript k Baseline left-parenthesis n right-parenthesis EndFraction

with gradient weight mu left-parenthesis n right-parenthesis. Using the simplified cost function (instantaneous value of the quadratic error)

(1.101)modifying above upper J with caret equals e squared left-parenthesis n right-parenthesis and e left-parenthesis n right-parenthesis equals x left-parenthesis n right-parenthesis minus sigma-summation Underscript k equals 1 Overscript p Endscripts b Subscript k Baseline left-parenthesis n right-parenthesis x left-parenthesis n minus k right-parenthesis

leads to

(1.102)StartFraction partial-differential modifying above upper J with caret Over partial-differential b Subscript k Baseline left-parenthesis n right-parenthesis EndFraction equals StartFraction partial-differential e squared left-parenthesis n right-parenthesis Over partial-differential b Subscript k Baseline left-parenthesis n right-parenthesis EndFraction equals 2 e left-parenthesis n right-parenthesis dot StartFraction partial-differential e left-parenthesis n right-parenthesis Over partial-differential b Subscript k Baseline EndFraction equals minus 2 e left-parenthesis n right-parenthesis x left-parenthesis n minus k right-parenthesis

and thus, for k equals 1 comma ellipsis comma p, the recursive LMS algorithm

(1.103)StartLayout 1st Row b Subscript k Baseline left-parenthesis n plus 1 right-parenthesis equals b Subscript k Baseline left-parenthesis n right-parenthesis plus mu left-parenthesis n right-parenthesis e left-parenthesis n right-parenthesis x left-parenthesis n minus k right-parenthesis period EndLayout

The gradient weight mu can be adjusted using the different LMS approaches listed in Table 1.1.

Table 1.1 Computing the gradient weight mu left-parenthesis n right-parenthesis.

Standard LMSmu left-parenthesis n right-parenthesis = const.
Normalized LMS (NLMS)mu left-parenthesis n right-parenthesis equals StartFraction alpha Over beta plus sigma-summation Underscript k equals 0 Overscript upper N minus 1 Endscripts x squared left-parenthesis n minus k right-parenthesis EndFraction
beta takes care of large mu left-parenthesis n right-parenthesis
Power Normalized (PNLMS)mu left-parenthesis n right-parenthesis equals StartFraction alpha Over upper N dot sigma Subscript x Superscript 2 Baseline left-parenthesis n right-parenthesis EndFraction
‐ Limitation:mu left-parenthesis n right-parenthesis equals min left-brace right-brace comma of mu mu left-parenthesis right-parenthesis n comma mu times times times max
‐ Recursive computation:sigma Subscript x Superscript 2 Baseline left-parenthesis n right-parenthesis equals lamda sigma Subscript x Superscript 2 Baseline left-parenthesis n minus 1 right-parenthesis plus left-parenthesis 1 minus lamda right-parenthesis x squared left-parenthesis n right-parenthesis comma
0 less-than lamda less-than 1

Linear Prediction for Coding and Source‐filter Processing

Linear prediction can be found in coding and source‐filter processing which have the same signal flow graph of operation, as shown in Fig. 1.19. The first part is the coding operation and consists of a forward prediction and coefficient calculation using the autocorrelation or LMS method. The coder transfer function is given by

(1.104)upper H Subscript upper C Baseline left-parenthesis z right-parenthesis equals 1 minus upper P left-parenthesis z right-parenthesis period

Then the error signal e left-parenthesis n right-parenthesis is quantized for the coding application and further processed for source‐filter modifications. The receiver performs a decoding operation by inverse filtering using the prediction filter and the corresponding coefficients from the coder or processed and modified coefficients. The decoder transfer function is given by

Schematic illustration of linear prediction for coding and source-filter processing.

Figure 1.19 Linear prediction for coding and source‐filter processing.

(1.105)upper H Subscript upper D Baseline left-parenthesis z right-parenthesis equals StartFraction 1 Over 1 minus upper P left-parenthesis z right-parenthesis EndFraction period

Source‐filter processing extracts, in the time domain, the source signal e left-parenthesis n right-parenthesis through linear prediction and simultaneously the filter coefficients b Subscript k of the prediction filter upper P left-parenthesis z right-parenthesis. The source signal is a whitened version of the input and the filter transfer function upper H Subscript upper D Baseline left-parenthesis z right-parenthesis represents the spectral envelope of the input x left-parenthesis n right-parenthesis. Both the source signal e left-parenthesis n right-parenthesis and the prediction coefficients b Subscript k can be modified according to specific tasks like sound morphing (keeping the source signal and modifying the spectral envelope).

1.9 Exercises

1. Signals and Systems

  1. Sketch the impulse responses:
    1. h left-parenthesis n right-parenthesis equals a dot delta left-parenthesis n right-parenthesis (amplifier);
    2. h left-parenthesis n right-parenthesis equals delta left-parenthesis n minus upper M right-parenthesis (delay by upper M samples);
    3. h left-parenthesis n right-parenthesis equals 0 comma 5 left-bracket delta left-parenthesis n right-parenthesis plus delta left-parenthesis n minus 1 right-parenthesis right-bracket (2‐tap moving average, simple lowpass filter);
    4. h left-parenthesis n right-parenthesis equals StartFraction 1 Over upper M EndFraction sigma-summation Underscript k equals 0 Overscript upper M Endscripts delta left-parenthesis n minus k right-parenthesis (upper M‐tap moving average, simple lowpass filter);
    5. h left-parenthesis n right-parenthesis equals a Superscript n Baseline dot epsilon left-parenthesis n right-parenthesis comma StartAbsoluteValue a EndAbsoluteValue less-than 1 (lowpass filter);
    6. h left-parenthesis n right-parenthesis equals a Superscript n Baseline dot sine left-parenthesis 2 pi one twentieth n right-parenthesis dot epsilon left-parenthesis n right-parenthesis comma StartAbsoluteValue a EndAbsoluteValue less-than 1 (lowpass filter);

    and compute y left-parenthesis n right-parenthesis for x left-parenthesis n right-parenthesis equals delta left-parenthesis n right-parenthesis plus delta left-parenthesis n minus 1 right-parenthesis using convolution (folding the impulse response and folding the input signal. Write a Matlab script for the computation of y left-parenthesis n right-parenthesis.

  2. Compute the output signals:
    1. y left-parenthesis n right-parenthesis equals upper A cosine left-parenthesis normal upper Omega n right-parenthesis star h left-parenthesis n right-parenthesis (eigen signal passing through system);
    2. y left-parenthesis n right-parenthesis equals x left-parenthesis n right-parenthesis plus a y left-parenthesis n minus 1 right-parenthesis comma StartAbsoluteValue a EndAbsoluteValue less-than 1 (first‐order lowpass filter);
    3. y left-parenthesis n right-parenthesis equals x left-parenthesis n right-parenthesis plus y left-parenthesis n minus 1 right-parenthesis (integrator);
    4. y left-parenthesis n right-parenthesis equals x left-parenthesis n right-parenthesis minus x left-parenthesis n minus 1 right-parenthesis (differentiator);

    for x left-parenthesis n right-parenthesis equals delta left-parenthesis n right-parenthesis and plot the output signals for x left-parenthesis n right-parenthesis equals sigma-summation Underscript k equals 0 Overscript 7 Endscripts delta left-parenthesis n minus k right-parenthesis using Matlab.

2. Discrete‐time Fourier Transform

  1. Compute the discrete‐time Fourier transform of:
    1. x left-parenthesis n right-parenthesis equals a dot delta left-parenthesis n right-parenthesis;
    2. x left-parenthesis n right-parenthesis equals delta left-parenthesis n minus upper M right-parenthesis;
    3. x left-parenthesis n right-parenthesis equals 0 comma 5 left-bracket delta left-parenthesis n right-parenthesis plus delta left-parenthesis n minus 1 right-parenthesis right-bracket;
    4. x left-parenthesis n right-parenthesis equals a Superscript n Baseline dot epsilon left-parenthesis n right-parenthesis comma StartAbsoluteValue a EndAbsoluteValue less-than 1;

    and plot the results using Matlab.

  2. Using the difference equation
    y left-parenthesis n right-parenthesis equals a sine left-parenthesis normal upper Omega 0 n right-parenthesis dot x left-parenthesis n minus 1 right-parenthesis plus 2 a cosine left-parenthesis normal upper Omega 0 n right-parenthesis dot y left-parenthesis n minus 1 right-parenthesis minus a squared dot y left-parenthesis n minus 2 right-parenthesis colon
    1. sketch the signal flow graph;
    2. compute the frequency response upper H left-parenthesis e Superscript j normal upper Omega Baseline right-parenthesis equals StartFraction upper Y left-parenthesis e Superscript j normal upper Omega Baseline right-parenthesis Over upper X left-parenthesis e Superscript j normal upper Omega Baseline right-parenthesis EndFraction;
    3. plot the magnitude response and phase response using Matlab;
    4. program the difference equation and plot the impulse response.

3. FIR and IIR Filters

  1. FIR filters with linear phase (even and odd symmetry, linear phase, constant group delay):
    1. h left-parenthesis n right-parenthesis equals 0.5 dot delta left-parenthesis n right-parenthesis plus 0.5 dot delta left-parenthesis n minus 1 right-parenthesis;
    2. h left-parenthesis n right-parenthesis equals 0.25 dot delta left-parenthesis n right-parenthesis plus 0.5 dot delta left-parenthesis n minus 1 right-parenthesis plus 0.25 dot delta left-parenthesis n right-parenthesis;
    3. h left-parenthesis n right-parenthesis equals 0.5 dot delta left-parenthesis n right-parenthesis minus 0.5 dot delta left-parenthesis n minus 1 right-parenthesis;
    4. h left-parenthesis n right-parenthesis equals 0.5 dot delta left-parenthesis n right-parenthesis minus 0.5 dot delta left-parenthesis n minus 2 right-parenthesis.

    Plot the impulse responses, magnitude and phase responses (freqz.m), pole/zero plots (zplane.m), and group delay (grpdelay.m). Discuss the results.

  2. Use FIR filters to approximate a given impulse response by truncating the length of the impulse response to upper N taps.
  3. Do experimentation with the Parks–McClellan design (firpm.m) and design several lowpass filters with linear phase. Use the Matlab files freqz.m and zplane.m for your evaluation.
  4. Show the IIR signal flow graphs of first‐order LP and HP filters, and second‐order BP filters. Verify the frequency responses.

4. Adaptive Filters

  1. Write a small script for linear prediction using the LMS algorithm. Use an audio signal and experiment with the prediction order and monitor the error.
  2. Modify the linear prediction approach by replacing d left-parenthesis n right-parenthesis equals x left-parenthesis n right-parenthesis star h left-parenthesis n right-parenthesis, where h left-parenthesis n right-parenthesis is the unknown system impulse response. Modify the code to perform system identification using the LMS algorithm.

References

  1. [Opp14] A.V. Oppenheim, A.S. Willsky, with H. Nawab: Signals and Systems, Pearson New International Edition, 2nd Edition, 2014.
  2. [Opp10] A.V. Oppenheim, R.W. Schafer, with J.R. Buck: Discrete‐time Signal Processing, Prentice Hall Signal Processing Series, 3rd Edition, 2010.

Notes

  1. 1 sinc left-parenthesis f right-parenthesis equals StartFraction sine left-parenthesis pi f right-parenthesis Over pi f EndFraction.
  2. 2 Expectation upper E left-brace e squared left-parenthesis n right-parenthesis right-brace equals sigma-summation Underscript n Endscripts e squared left-parenthesis n right-parenthesis.
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset