§4.2 The Frequency Response The function H(ejo) is called the magnitude response and the function 0(a)is called the phase response of the lti discrete-time system Design specifications for the lti discrete-time system, in many applications, are given in terms of the magnitude response or the phase response or both
§4.2 The Frequency Response • The function | H(ej) | is called the magnitude response and the function () is called the phase response of the LTI discrete-time system • Design specifications for the LTI discrete-time system, in many applications, are given in terms of the magnitude response or the phase response or both
§4.2 The Frequency Response .. In some cases, the magnitude function is specified in decibels as G(O)=20logo H(eJo) dB where G(o) is called the gain function The negative of the gain function A(o)=-G() is called the attenuation or loss function
§4.2 The Frequency Response • In some cases, the magnitude function is specified in decibels as G() = 20log10| H(ej) | dB where G() is called the gain function • The negative of the gain function A() = - G() is called the attenuation or loss function
§4.2 The Frequency Response Note: Magnitude and phase functions are real functions of@, whereas the frequency response is a complex function of a If the impulse response hn is real then the magnitude function is an even function of a: H(eo)=h(e Jo ) and the phase function is an odd function of a 6(0)=-6(-0)
§4.2 The Frequency Response • Note: Magnitude and phase functions are real functions of , whereas the frequency response is a complex function of • If the impulse response h[n] is real then the magnitude function is an even function of : |H(ej)| = |H(e - j)| and the phase function is an odd function of : () = - (-)
84.3 Frequency Response Computation Using MATLAB The function freqz(th, w) can be used to determine the values of the frequency response vector h at a set of given frequency points w From h, the real and imaginary parts can be computed using the functions real and imag, and the magnitude and phase functions using the functions abs and angle
§4.3 Frequency Response Computation Using MATLAB • The function freqz(h,w) can be used to determine the values of the frequency response vector h at a set of given frequency points w • From h, the real and imaginary parts can be computed using the functions real and imag, and the magnitude and phase functions using the functions abs and angle
84.3 Frequency Response Computation Using MATLAB Example- Program 4 1(p. 206)can be used to generate the magnitude and gain responses of an M-point moving average filter as shown below M=5 M=14 0.8 0.6 0.2 M=5 150 M=14 04 0.2 0.6 0.8
§4.3 Frequency Response Computation Using MATLAB • Example - Program 4_1(p.206) can be used to generate the magnitude and gain responses of an M-point moving average filter as shown below