11.5 FIR Filter Design 687FIGURE 11.23
Low-pass FIR filters using (a)
rectangular and (b) Hamming
windows.
−0.1 051015 2000.10.20.3h
[n
]nω/π0 0.5 1
− 100− 80− 60− 40− 20020log10|H
(ejω
)|(dB)− 100− 80− 60− 40− 20020log10|H
(ejω
)|(dB)0 0.5 1
ω/π0 0.5 100.20.40.60.81ω/π|H(ejω
)|ω/π0 0.5 1−8−6−4−20<H(ejω
)−10−50<H(ejω
)0 0.5 100.20.40.60.81ω/π0 0.5 1
ω/π|H(ejω
)|051015 2000.10.20.3h
[n]n(b)(a)%%%%%%%%%%%%%%%%
% Example 11.13---FIR filter from ‘fir’
%%%%%%%%%%%%%%%%
M = 14;wc = 0.2;wo = 1;wind = 4;
[b] = fir(M,wc,wo,wind);
[H,w] = freqz(b,1,256);
The results are shown in Figure 11.24. Notice the symmetry of the impulse response with respect
toM/ 2 =7 gives a linear phase in the passband of the high-pass filter. The second lobe of the gain
in dB is about−50 dB.