Chapter 3 The Discrete-Time Fourier Transform - 清華大 …cwlin/courses/dsp/notes/ch3_Mitr… ·...

34
2008/3/17 1 The Discrete-Time Fourier Transform Chapter 3 © The McGraw-Hill Companies, Inc., 2007 Original PowerPoint slides prepared by S. K. Mitra 3-1-1 清大電機系林嘉文 [email protected] 03-5731152 Continuous-Time Fourier Transform Definition – The CTFT of a continuous-time signal x a (t) is given by Often referred to as the Fourier spectrum or simply the spectrum of the continuous-time signal Definition – The inverse CTFT of a Fourier transform X a ( j) is given by © The McGraw-Hill Companies, Inc., 2007 Original PowerPoint slides prepared by S. K. Mitra 3-1-2 Often referred to as the Fourier integral A CTFT pair will be denoted as

Transcript of Chapter 3 The Discrete-Time Fourier Transform - 清華大 …cwlin/courses/dsp/notes/ch3_Mitr… ·...

  • 2008/3/17

    1

    The Discrete-Time Fourier Transform

    Chapter 3

    The McGraw-Hill Companies, Inc., 2007Original PowerPoint slides prepared by S. K. Mitra 3-1-1

    [email protected]

    Continuous-Time Fourier Transform Definition The CTFT of a continuous-time signal xa(t)

    is given by

    Often referred to as the Fourier spectrum or simply the spectrum of the continuous-time signal

    Definition The inverse CTFT of a Fourier transform Xa( j) is given by

    The McGraw-Hill Companies, Inc., 2007Original PowerPoint slides prepared by S. K. Mitra 3-1-2

    Often referred to as the Fourier integral A CTFT pair will be denoted as

  • 2008/3/17

    2

    Continuous-Time Fourier Transform is real and denotes the continuous-time angular

    frequency variable in radians In general, the CTFT is a complex function of in the

    range < < It can be expressed in the polar form as

    The quantity Xa( j) is called the magnitude spectrumwhere

    The McGraw-Hill Companies, Inc., 2007Original PowerPoint slides prepared by S. K. Mitra 3-1-3

    and the quantity a() is called the phase spectrum Both spectrums are real functions of In general, the CTFT Xa( j) exists if xa(t) satisfies the

    Dirichlet conditions

    Dirichlet Conditions(a) The signal xa(t) has a finite number of discontinuities and a

    finite number of maxima and minima in any finite interval(b) The signal is absolutely integrable, i.e.,

    If the Dirichlet conditions are satisfied, then

    ( )

  • 2008/3/17

    3

    Energy Density Spectrum The total energy Ex of a finite energy continuous-time

    complex signal xa(t) is given by

    which can also be rewritten as

    The McGraw-Hill Companies, Inc., 2007Original PowerPoint slides prepared by S. K. Mitra 3-1-5

    Interchanging the order of the integration we get

    Energy Density Spectrum Hence

    This is commonly known as the Parsevals relation for finite-energy continuous-time signals

    The quantity Xa( j)2 is called the energy density spectrum of xa(t) and usually denoted as

    The McGraw-Hill Companies, Inc., 2007Original PowerPoint slides prepared by S. K. Mitra 3-1-6

    The energy over a specified range of a b can be computed using

  • 2008/3/17

    4

    Band-limited Continuous-Time Signals (1/2)

    A full-band, finite-energy, continuous-time signal has a spectrum occupying the whole frequency range

  • 2008/3/17

    5

    Discrete-Time Fourier Transform

    Definition - The discrete-time Fourier transform (DTFT)X (e j) of a sequence x[n] is given by( ) q [ ] g y

    In general, X(ej) is a complex function of as follows

    Xre(ej) and Xim(ej ) are, respectively, the real and f ( j ) f f

    The McGraw-Hill Companies, Inc., 2007Original PowerPoint slides prepared by S. K. Mitra 3-1-9

    imaginary parts of X(ej), and are real functions of X(ej) can alternately be expressed as

    where

    Discrete-Time Fourier Transform X(ej) is called the magnitude function () is called the phase function ( ) p In many applications, the DTFT is called the Fourier

    spectrum Likewise, X(ej) and () are called the magnitude and

    phase spectra For a real sequence x[n], X(ej) and Xre(ej) are even

    functions of whereas () and X (ej) are odd

    The McGraw-Hill Companies, Inc., 2007Original PowerPoint slides prepared by S. K. Mitra 3-1-10

    functions of , whereas, () and Xim(ej ) are odd functions of

    Note:The phase function () cannot be uniquely specified for any DTFT

    )()2)(( )()()( jjkjjj eeXeeXeX == +

  • 2008/3/17

    6

    Discrete-Time Fourier Transform If not specified, we shall assume that the phase function () is restricted to the following range of values:

    ()

  • 2008/3/17

    7

    Discrete-Time Fourier Transform

    The magnitude and phase of the DTFT X (e j) =1/(1 0 5e j) are shown below0.5e j) are shown below

    The McGraw-Hill Companies, Inc., 2007Original PowerPoint slides prepared by S. K. Mitra 3-1-13

    Discrete-Time Fourier Transform The DTFT X(ej) of x[n] is a continuous function of It is also a periodic function of with a period 2:

    Therefore

    represents the Fourier series representation of the

    The McGraw-Hill Companies, Inc., 2007Original PowerPoint slides prepared by S. K. Mitra 3-1-14

    represents the Fourier series representation of the periodic function

    As a result, the Fourier coefficients x[n] can be computed from using the Fourier integral

  • 2008/3/17

    8

    Discrete-Time Fourier Transform Inverse discrete-time Fourier transform:

    Proof

    The order of integration and summation can be interchanged if the summation inside the brackets converges uniformly i e X(ej) exists

    The McGraw-Hill Companies, Inc., 2007Original PowerPoint slides prepared by S. K. Mitra 3-1-15

    converges uniformly, i.e. X(ej) existsThen

    Discrete-Time Fourier Transform Now

    Hence

    The McGraw-Hill Companies, Inc., 2007Original PowerPoint slides prepared by S. K. Mitra 3-1-16

  • 2008/3/17

    9

    Discrete-Time Fourier Transform Convergence Condition - An infinite series of the form

    may or may not converge Let

    Then for uniform convergence of X(ej)

    The McGraw-Hill Companies, Inc., 2007Original PowerPoint slides prepared by S. K. Mitra 3-1-17

    Now, if x[n] is an absolutely summable sequence, i.e., if

    Discrete-Time Fourier Transform

    Then

    for all values of Thus, the absolute summability of x[n] is a sufficient

    condition for the existence of the DTFT X(ej)

    The McGraw-Hill Companies, Inc., 2007Original PowerPoint slides prepared by S. K. Mitra 3-1-18

  • 2008/3/17

    10

    Discrete-Time Fourier Transform Example the sequence x[n] = n[n] for || < 1 is

    absolutely summable as

    and its DTFT X(ej) therefore converges to 1/(1 ej)uniformly

    Since

    [ ] Nimpulse response h[n], of length N 1, h[n] 0 for n N

    Hence, ytr[n] = 0 n > N 1

    Here the output reaches the steady-state value ysr[n] = H(ej) ej at n = N

    The McGraw-Hill Companies, Inc., 2007Original PowerPoint slides prepared by S. K. Mitra 3-2-54

  • 2008/3/17

    28

    The Concept of Filtering (1/8) Filtering is to pass certain frequency components in an

    input sequence without any distortion (if possible) while blocking other frequency componentsblocking other frequency components

    The key to the filtering process is

    It expresses an arbitrary input as a linear weighted sum of an infinite number of exponential/sinusoidal sequences

    The McGraw-Hill Companies, Inc., 2007Original PowerPoint slides prepared by S. K. Mitra 3-2-55

    p q Thus, by appropriately choosing the values of |H(ej)| of

    the filter at concerned frequencies, some of these components can be selectively heavily attenuated or filtered with respect to the others

    The Concept of Filtering (2/8) Consider a real-coefficient LTI discrete-time system

    characterized by a magnitude function

    We apply the following input to the systemx[n] = Acos1n + Bcos2n, 0 < 1 < c < 2 <

    Because of linearity, the output of this system is of the form

    The McGraw-Hill Companies, Inc., 2007Original PowerPoint slides prepared by S. K. Mitra 3-2-56

    As

    the output reduces to

    ( ) ( )1 21 0j jH e H e

    (lowpass filter)

  • 2008/3/17

    29

    The Concept of Filtering (3/8) Example - The input consists of two sinusoidal sequences

    of frequencies 0.1 rad/sample and 0.4 rad/sample We need to design a highpass filter that will only pass the We need to design a highpass filter that will only pass the

    high-frequency component of the input Assume the filter to be an FIR filter of length 3 with an

    impulse response:h[0] = h[2] = , h[1] =

    The convolution sum description of this filter is given by

    The McGraw-Hill Companies, Inc., 2007Original PowerPoint slides prepared by S. K. Mitra 3-2-57

    y[n] = h[0]x[n] + h[1]x[n 1] + h[2]x[n 2]= x[n] + x[n 1] + x[n 2]

    Design Objective: Choose suitable values of and so that the output is a sinusoidal sequence with a frequency 0.4 rad/sample

    The Concept of Filtering (4/8) The frequency response of the FIR filter is given by

    The magnitude and phase functions are|H(ej)| = 2 cos +

    The McGraw-Hill Companies, Inc., 2007Original PowerPoint slides prepared by S. K. Mitra 3-2-58

    | ( )| () =

    To block the low-frequency component and pass the high-frequency one, the magnitude function at = 0.1 should be equal to zero, while that at = 0.4 should be equal to one

  • 2008/3/17

    30

    The Concept of Filtering (5/8) Thus, the two conditions that must be satisfied are

    |H(ej0.1)| = 2cos(0.1) + = 0| ( )| ( )

    |H(ej0.4)| = 2cos(0.4) + = 0 Solving the above two equations we get

    = 6.76195 =13.456335

    The McGraw-Hill Companies, Inc., 2007Original PowerPoint slides prepared by S. K. Mitra 3-2-59

    Thus the output-input relation of the FIR filter is given byy[n] = 6.76195(x[n] + x[n 2]) + 13.456335x[n 1]

    where the input isx[n] = {cos(0.1n) + cos(0.4n)}[n]

    The Concept of Filtering (6/8) The waveforms of input and output signals are shown

    below

    The McGraw-Hill Companies, Inc., 2007Original PowerPoint slides prepared by S. K. Mitra 3-2-60

  • 2008/3/17

    31

    The Concept of Filtering (7/8) The first seven samples of the output are shown below

    It can be seen that neglecting the least significant digit

    The McGraw-Hill Companies, Inc., 2007Original PowerPoint slides prepared by S. K. Mitra 3-2-61

    It can be seen that, neglecting the least significant digity[n] = cos(0.4(n 1)) for n 2

    Computation of the present output value requires the knowledge of the present and two previous input samples

    The Concept of Filtering (8/8)

    Hence, the first two output samples, y[0] and y[1], are the result of assumed zero input sample values at n = 1 andresult of assumed zero input sample values at n 1 and n = 2

    Therefore, first two output samples constitute the transient part of the output

    Since the impulse response is of length 3, the steady-state is reached at n = N = 2Note also that the output is delayed version of the high

    The McGraw-Hill Companies, Inc., 2007Original PowerPoint slides prepared by S. K. Mitra 3-2-62

    Note also that the output is delayed version of the high-frequency component cos(0.4n) of the input, and the delay is one sample period

  • 2008/3/17

    32

    Phase Delay If the input x[n] to an LTI system H(ej) is a sinusoidal

    signal of frequency ox[n] = Acos(on + ), < n <

    Then, the output y[n] is also a sinusoidal signal of the same frequency o but lagging in phase by (o) radians:

    x[n] = A|H(ej)| cos(on + (o) + ), < n < We can rewrite the output expression as

    x[n] = A|H(ej)| cos( ( n ( ) + )) < n <

    The McGraw-Hill Companies, Inc., 2007Original PowerPoint slides prepared by S. K. Mitra 3-2-63

    x[n] = A|H(ej )| cos(o( n p(o) + )), < n < where p(o) = (o) / o is called the phase delay

    The minus sign in front indicates phase lag In general, y[n] will not be a delayed replica of x[n] unless

    the phase delay is an integer

    Group Delay When the input is composed of several sinusoidal

    components with different frequencies that are not harmonicall related each component ill go thro ghharmonically related, each component will go through different phase delays

    In this case, the signal delay is determined using the group delay defined by

    In defining the group delay it is assumed that the phase

    The McGraw-Hill Companies, Inc., 2007Original PowerPoint slides prepared by S. K. Mitra 3-2-64

    In defining the group delay, it is assumed that the phase function is unwrapped so that its derivatives exist

    Group delay has a physical meaning only with respect to the underlying continuous-time functions associated with y[n] and x[n]

  • 2008/3/17

    33

    Phase and Group Delay A graphical comparison of the two types of delays:

    The McGraw-Hill Companies, Inc., 2007Original PowerPoint slides prepared by S. K. Mitra 3-2-65

    Example - The phase function of the FIR filter y[n] = x[n] + x[n 1] + x[n 2] is () =

    Hence its group delay g() is given by verifying the result obtained earlier by simulation

    Phase and Group Delay Example - For the M-point moving-average filter

    the phase function is

    Hence its group delay is

    ( ) ( )

    =

    +

    =

    2/

    1

    22

    1 M

    k MkM

    The McGraw-Hill Companies, Inc., 2007Original PowerPoint slides prepared by S. K. Mitra 3-2-66

    Hence its group delay is

  • 2008/3/17

    34

    Computing Phase and Group Delay Using MTALAB

    Phase delay can be computed using the function phasedelay

    Group delay can be computed using the function grpdelay

    The McGraw-Hill Companies, Inc., 2007Original PowerPoint slides prepared by S. K. Mitra 3-2-67