Part B:Frequency Response 1.1 Definition 1.The Frequency Response of an LTI Discrete-Time Chapter 3B 习yx轮加 An LTI discrete-time system is completely 1.1 Definition characterized in the time-domain by its ●●● ●●● 1.2 Frequency-Domain Characterization of the LTI impulse response sequence h(n). discrete-time system The Frequency Response of an Thus.the transform-domain representation of 1.3 Frequeacy Response Computing Using Matlab LTI Discrete-Time System a discrete-time signal can also be equally 1.4 The Concept of Filtering applied to the transform-domain 2.Phase and Group Delays representation of an LTI discrete-time system. 2.1 Definition 2.2 Phase and Group delay Computation Using Matlab 2 1.1 Definition 1.1 Definition 1.1 Definition Such transform-domain representations provide additional insights into the behavior In this course we shall be concerned with LTI .Applying the DTFT to the difference equation of such systems. discrete-time systems characterized by linear and making use of the linearity and the time- constant coefficient difference equations of invariance properties,we arrive at the input- It is easier to design and implement these the form: output relation in the transform-domain as systems in the transformed-domain for certain applications. 4n-)=2A- Y(e) e-fo Y(e) We consider now the use of the DTFT in developing the transform domain DTFT representations of an LTI system. n 5
Chapter 3B Chapter 3B The Frequency Response of an LTI Discrete-Time System Part B: Frequency Response 1. The Frequency Response of an LTI Discrete The Frequency Response of an LTI Discrete-Time system 1.1 Definition 1.2 Freq y uenc -Domain Characterization of the LTI Domain Characterization of the LTI discrete discrete-time system time system 1.3 Freq yp pg g uency Response Com onse Computing Using Matlab 1.4 The Concept of Filtering 2. Phase and Group Delays 2.1 Definition 2 2.2 Phase and Group delay Computation Using Matlab 1.1 Definition An LTI discrete-time sy py stem is completely characterized in the time-domain by its imppq ulse response sequence {h(n)}. Thus, the transform transform-domain representation domain representation of a discrete a discrete-time signal can also be equally can also be equally applied to the transform transform-domain representation representation of an LTI discrete an LTI discrete-time system time system. 3 1.1 Definition Such transform-domain representations provide additional provide additional insights insights into the behavior into the behavior of such systems. It is easier to design and implement these systems in the transformed-domain for certain applications. We consider now the use of the We consider now the use of the DTFT in developing the transform domain representations of an LTI system 4 representations of an LTI system. 1.1 Definition In this course we shall be concerned with LTI discrete-time systems characterized by linear constant coefficient difference equations of constant coefficient difference equations of the form: N M 0 0 () () k k k k d y n k pxn k k k 0 0 5 1.1 Definition App y g l in the DTFT to the difference equation and making use of the linearity and the timeinvariance properties, we arrive at the input invariance properties, we arrive at the inputoutput relation in the transform-domain as N M 0 0 () () jk j jk j k k k k de Y e pe X e ( ) ( ) DTFT 6 y(n) x(n)
1.1 Definition 1.1 Definition 1.1 Definition Most discrete-time signals encountered in An important property of an LTI system is Its I-O relationship in the time domain is given practice can be represented as a linear that for certain types of input signals,called by the convolution sum. combination of a very large,maybe infinite eigen functions,the output signal is the input number of sinusoidal discrete-time signals of signal multiplied by a complex constant. m=∑xkhn=k0=之hx-⊙ different angular frequencies. We consider one such eigen function as the .If the input is of the form Thus,knowing the response of the LTI system input. to a single sinusoidal signal,we can x(n)=efcm -0<n<0 determine its response to more complicated Consider the following LTI system then signals by making use of the superposition x(n) h(m) 一n property. 1.1 Definition 1.1 Definition 1.1 Definition ·Then we can write Definition In some cases,the magnitude function is y(n)=H(e)eiam .The DTFT of the impulse response of an LTI specified in decibels as Thus for a complex exponential input system is called the Frequency Response of G(@)=20logo H(ei)dB signal e,the output of an LTI discrete-time this system where G(@)is called the gain function system is also a complex exponential signal of H(ei)=H(e2))=H(e)+jH (e) The negative of the gain function the same frequency multiplied by a complex constant H(e) A(w)=-G() Thus e"is an eigen function of the system is called the attenuation or loss function phase t2
1.1 Definition Most discrete-time signals encountered in practice can be represented as a linear practice can be represented as a linear combination of a very large, maybe infinite number of number of sinusoidal discrete sinusoidal discrete-time signals time signals of different angular frequencies. Th k i th f th LTI t Thus, knowing the response of the LTI system to a single sinusoidal signal, we can d t i it t li t d determine its response to more complicated signals by making use of the superposition 7 property. 1.1 Definition An important property of an LTI system is that for certain types of input signals called that for certain types of input signals, called eigen functions functions, the output signal is the input si l lti li d b l t t ignal multiplied by a complex cons ex constant. We consider one such eigen function function as the input. Consider the following LTI system Consider the following LTI system x(n) h(n) y(n) 8 ( ) ( ) 1.1 Definition Its I-O relationship in the time domain is given by the convolution sum by the convolution sum. y() ()( ) ()( ) n xkhn k hkxn k If the input is of the form () ()( ) ()( ) k k y then ( ) j n xn e n then ( ) () () () j nk jk jn y n hke hke e 9 k k ( ) j H e 1.1 Definition Then we can write j j Thus for a complex exponential input () ( ) n yn He e Thus for a complex exponential input signal , the output of an LTI discrete-time system is also a complex exponential signal of j n e system is also a complex exponential signal of the same frequency multiplied by a complex constant ( ) j H e Thus is an eigen function of the system H e( ) j n e 10 1.1 Definition Definition The DTFT of h i l f LTI f the impulse response of an LTI system is called the Frequency Response of this system 2 () ( ) () () j jj j H H H jH arg{ ( )} () ( ) () () ( ) j j jj j re im j j He H e H e H e jH e He e He e ( ) magnitude phase 11 response phase response 1.1 Definition In some cases, the magnitude function is specified in specified in decibels as 10 ( ) 20log ( ) dB j H e where is called the gain function Th ti f th i f ti ( ) The negative of the gain function () () is called the attenuation or loss function () () 12
1.2 Frequency-Domain Characterization 1.2 Frequency-Domain Characterization 1.2 Frequency-Domain Characterization of the LTI Discrete-Time System of the LTI Discrete-Time System of the LTI Discrete-Time System Interchanging the summation signs on the The convolution sum description of the LTI It follows from the previous equation discrete-time system is given by right-hand side and rearranging we arrive at H(e)=Y(e)/X(e) a)=∑hk)xn-) Ye)=2M-ke For an LTI system described by a linear constant coefficient difference equation of the Taking the DTFT of both sides we obtain form we have Y(e)= (2a- pe-fus H(e)=2- de-jau 13 =H(e)X(e) 15 1.3 Frequency Response Computation 1.3 Frequency Response Computation 1.3 Frequency Response Computation using Matlab using Matlab using Matlab The function freqz (h,w)can be used to Example determine the values of the frequency response .Consider a moving-average filter vector h at a set of given frequency points w 1/M,0≤n≤M-1 From /the real and imaginary parts can be h(n)= 0,otherwise computed using the functions real and imag, .Program 3_2 can be used to generate the and the magnitude and phase functions using the functions abs and angle magnitude and gain responses of an M-point moving average filter as shown in the next slide 常
1.2 Freq y uenc -Domain Characterization of the LTI Discrete-Time System The convolution sum description of the LTI discrete-time system is given by () ()( ) hk k Taking the DTFT of both sides we obtain () ()( ) k y n h k x n k Taking the DTFT of both sides we obtain ( ) ()( ) j j n Ye hkxn k e ( ) ()( ) n k Ye hkxn k e 13 1.2 Freq y uenc -Domain Characterization of the LTI Discrete-Time System Interchanging the summation signs on the right-hand side and rearranging we arrive at hand side and rearranging we arrive at ( ) () ( ) j jn Ye hk xn ke ( ) ( ) () ( ) ( ) () k n lnk j lk hk l ( ) ( ) () j lk k l h k x l e ( ) () j l j k k l hk xle e ( )( ) 14 j j He Xe 1.2 Freq y uenc -Domain Characterization of the LTI Discrete-Time System It follows from the previous equation F LTI t d ib d b li ( ) ( )/ ( ) j j j He Ye Xe For an LTI system described by a linear constant coefficient difference equation of the f h orm we have M j k k p e 0 ( ) j kN j k H e d e 0 15 k k d e 1.3 Freq yp p uency Response Computation using Matlab The function The function freqz(h,w) freqz(h,w) can be used to can be used to determine the values of the frequency response vector h at a set of given frequency points at a set of given frequency points w From h, the real and imaginary parts can be comput d i th f ti ted using the functions real and imag, and the magnitude and phase functions using th f ti the functions abs and angle 16 1.3 Freq yp p uency Response Computation using Matlab Example Consider a moving-average filter 1/ 0 1 M nM ( ) 0 otherwise M nM h n ˈˈ Program 3_2 can be used to generate the mag gp nitude and gain responses of an M-point moving average filter as shown in the next slide 17 1.3 Freq yp p uency Response Computation using Matlab 1 Magnitude Response 100 Phase Response 0.8 M=5 M=14 0 50 e s 0.4 0.6 Magnitude 100 -50 0 Phase, degre e 0.2 -150 P-100 M=5 M=14 0 0.2 0.4 0.6 0.8 1 0 / 0 0.2 0.4 0.6 0.8 1 -200 / 18
1.4 The Concept of Filtering 1.4 The Concept of Filtering 1.4 The Concept of Filtering One application of an LTI discrete-time system The key to the filtering process is By appropriately choosing the values of the is to pass certain frequency components in an 1 magnitude function H(e)of the LTI digital input sequence without any distortion (if "X(e)edo filter at frequencies comresponding to the possible)and to block other frequency frequencies of the sinusoidal components of components. It expresses an arbitrary input as a linear the input,some of these components can be Such systems are called digital filters and one weighted sum of an infinite number of selectively heavily attenuated or filtered with of the main subjects of discussion in this exponential sequences,or equivalently,as a respect to the others. course. linear weighted sum of sinusoidal sequences. 19 20 21 1.4 The Concept of Filtering 1.4 The Concept of Filtering 1.4 The Concept of Filtering To understand the mechanism behind the ●We apply an input ●As design of frequency-selective filters,consider a x(m)=Acos@n+Bcos,n,0<叫<0.<2<π H(em1H(e典≥o real-coefficient LTI discrete-time system to this system the output reduces to characterized by a magnitude function. Because of linearity,the output of this system (m)兰AH(e)cos(n+队a) H( 「l,0≤ad≤a is of the form Thus,the system acts like a lowpass filter 0,@.<@≤π m)=AH(em)cos(on+(a》 In the following example,we consider the design of a very simple digital filter. +B H(e)cos(@,n+0(@)) 名 Eigen-function.conjugatesymmetric for real h(n) 23
1.4 The Concept of Filtering One application of an LTI discrete-time system is to pass certain frequency components in an inpq y ( ut sequence without any distortion (if possible) and to block other frequency components. Such systems are called digital filters and one of the main subjects of discussion in this of the main subjects of discussion in this course. 19 1.4 The Concept of Filtering The key gp to the filtering process is 1 () ( ) 2 j jn xn X e e d It expresses an arbitrary input as a linear - () ( ) 2 p yp weighted sum of an infinite number of exp q , q y, onential sequences, or equivalently, as a linear weighted sum of sinusoidal sequences. 20 1.4 The Concept of Filtering By pp p y g appropriately choosing the values of the magnitude function of the LTI digital filter at frequencies corresponding to the ( ) j H e q pg frequencies of the sinusoidal components of the inp, p ut some of these components can be selectively heavily attenuated or filtered with respect to the others. respect to the others. 21 1.4 The Concept of Filtering To understand the mechanism behind the To understand the mechanism behind the design of frequency frequency-selective selective filters, consider a real-coefficient LTI discrete coefficient LTI discrete-time system time system characterized by a magnitude function. 1, 0 ( ) 0 j c H e 0, c 22 1.4 The Concept of Filtering We apply an input to this system 1 212 ( ) cos cos , 0 c xn A n B n to this system Because of linearity,p y the output of this system is of the form 1 ( ) ( ) cos( ( )) j yn AH e n 1 2 1 1 2 2 ( ) ( ) cos( ( )) ( ) cos( ( )) j j yn AH e n BH e n 23 2 2 ( ) ( ( )) Eigen-function, conjugate-symmetric for real h(n) 1.4 The Concept of Filtering As 1 ( )1 j H 2 ( )0 j H the output reduces to 1 ( )1 j H e 2 ( )0 j H e e ou pu educes o 1 1 1 ( ) ( ) cos( ( )) j yn AH e n Thus, the system acts like a lowpass filter In the following example, we consider the In the following example, we consider the design of a very simple digital filter. 24
1.4 The Concept of Filtering 1.4 The Concept of Filtering 1.4 The Concept of Filtering Example The magnitude and phase functions are .Design of a high pass digital filter H(e)=2acos@+ 0=-w The inputx(n)=[cos(0.In)+cos(0.4n)u(n) 0 In order to block the low-frequency component, which consists of two frequency components Note that h(n)is a linear phase FIR filter the magnitude function at w=0.1 should be 0.1 rad/sample and 0.4 rad/sample. which will be discussed in the latter chapters equal to zero For simplicity,assume the filter to be an FIR The frequency response of this filter is given Likewise,to pass the high-frequency filter of length 3 with an impulse response: by H(e)=h(0)+h(l)e-+h(2)e2 component,the magnitude function at =0.4 should be equal to one 25 =(2a cos@+B)e-i 2 27 1.4 The Concept of Filtering 1.4 The Concept of Filtering 1.4 The Concept of Filtering Thus,the two conditions that must be satisfied Figure below shows the plots generated by Figure below shows the frequency response are running program 33 of this highpass filter 2acos0.1+B=0 2acos0.4+B=1 Solving the above two equations we get a=-6.76195B=13.456335 .Thus the output-input relation of the FIR filter is given by ym)=-6.76195x(m)+13.456335x(0n-1) -6.76195x(m-2) 西 30 rad/samnle
1.4 The Concept of Filtering Example Design of a high pass digital filter The input The input xn n n un ( ) cos(0 1 ) cos(0 4 ) ( ) which consists of two frequency components 0 1 d/ l d 0 4 d/ l xn n n un ( ) cos(0 .1 ) cos(0 .4) () 0.1 rad/sample and 0.4 rad/sample. For simp y licit , assume the filter to be an FIR filter of length 3 with an impulse response: 25 1.4 The Concept of Filtering h(n) 0 12 n Note that h(n) is a linear phase FIR filter which will be discussed in the latter chapters 0 1 2 n which will be discussed in the latter chapters The frequency response of this filter is given by 2 ( ) (0) (1) (2) (2 ) j j j j H e h he h e 26 (2 cos ) j e 1.4 The Concept of Filtering The magnitude and phase functions are j ( ) In order to block the low-frequency component, ( ) 2 cos j H e ( ) o de to b oc t e ow eque cy co po e t, the magnitude function at = 0.1 should be equal to zero equal to zero Likewise, to pass the high pass the high-frequency frequency component, the magnitude function at = 0.4 should be equal to one 27 1.4 The Concept of Filtering Thus, the two conditions that must be satisfied are Sli h b i 2 cos0.1 0 2 cos0.4 1 Solving the above two equations we get 6.76195 13.456335 Thus the output-input relation of the FIR filter is given by ( ) 6.76195 ( ) 13.456335 ( 1) 6 76195 ( 2) yn xn xn x n 28 6.76195 ( 2) x n 1.4 The Concept of Filtering Figure below shows the plots generated by running program 3 3 4 y(n) x (n) running program 3_3 2 3 d e x2(n) x1(n) 1 Amplitu d 0 29 0 20 40 60 80 100 -1 Time index n 1.4 The Concept of Filtering Figure below shows the frequency response of this highpass filter of this highpass filter 1 0 6 0.8 ) 0.4 0.6 H(e j ) 0.2 30 0 0.1 0.2 0.3 0.4 0 rad/sample