1 / 43

FIR Filters

FIR Filters. FIR filters have transfer functions of the following form:. The impulse response is. This impulse response function is finite in duration . Such filters are referred to as finite impulse response or FIR filters.

Download Presentation

FIR Filters

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. FIR Filters

  2. FIR filters have transfer functions of the following form: The impulse response is

  3. This impulse response function is finite in duration. Such filters are referred to as finite impulse response or FIR filters. Any filter whose transfer function does not have a denominator will have an impulse response that is finite in duration. There are no (realizable) analog filters with a finite impulse response, or (stable) analog filters whose transfer function does not have a denominator.

  4. So why bother with FIR filters? FIR filters do have one interesting property: unlike IIR filters, they can have linear phase response. w H(ejw)

  5. Example: Find the phase response of Solution: We let z=ejw, and find the angle of the complex value.

  6. *The phase must be evaluated as a limit here.

  7. FIR filters do not always have linear phase. As an example,

  8. Now, let us find the criteria for an FIR filter to have linear phase. Suppose the FIR filter was of the simple form

  9. If b0 = b1 = b, we have

  10. The phase response of this filter is which is in fact linear.

  11. If b0 = -b1 = b, we have The phase response is

  12. As it turns out, as long as the coefficients aresymmetric (even or odd), the phase will be linear. The following are examples of linear-phase FIR filters:

  13. Exercise: For each of the previous examples, find the (linear) relationship of phase to frequency H(ejw).

  14. Linear Phase and Group Velocity What is so special about linear phase? Let f(w) be the phase response of a filter. Without loss of generality, let us assume that the filter has constant magnitude response.

  15. Suppose we pass a sinewave through this filter. The corresponding output would be

  16. Suppose we pass another sinewave through this filter. The corresponding output would be

  17. Now suppose we pass the sum of the sinewaves through this filter. The corresponding output would be

  18. Now if the phase response is linear, i.e., then the output would be

  19. The filter effectively shifts different frequencies by the same amount in time. If the filter shifted the frequencies by different amounts in time (as it would with non-linear phase), then the signals would be delayed by different amounts and would not be aligned at the output of the filter. Such a non-aligned result is called dispersion. The derivative of the phase response is called the group velocity. For linear phase, the group velocity is constant (-b).

  20. Design of FIR Filters Since there are no analog filters with a finite-duration impulse response, FIR filters can notbe patterned after analog filters—new, original design techniques have to be developed. The first design technique is the Fourier SeriesMethod. The second design technique is the Minimum Mean-Square Error Technique.

  21. The Fourier Series Method Suppose we wished to design a filter with a desired frequency response, Hd(ejw). A typical example would be the following: Hd(ejw) w -wc wc

  22. Let us take a periodic extension (in frequency domain) of this function: … … w -2p 2p We could represent this periodic extension by a Fourier series (in frequency domain).

  23. The “period” would be 2p, and the fundamental “frequency” would be 2p/2p=1. where

  24. We can readily construct the z-transform transfer function of this filter: Thus, the coefficients cn turn out to be nearly the FIR filter coefficients bn.

  25. Example: Suppose the cutoff frequency of our desired filter is wc=p/2. Find the coefficients of an FIR filter. Solution:We calculate the filter coefficients as follows:

  26. For a practical filter the summation in the Fourier series cannot be infinite: we must truncate the Fourier series to n=-r to r (where r is a finite integer): For r=5, the transfer function for our wc=p/2 filter is as follows:

  27. Plots of the frequency response, for various values of r, are shown on the following slide.

  28. While the frequency response improves for higher orders, you will notice that there is always “rippling” at the transition (even for higher orders). This “rippling” is called Gibbs phenomenon. This “rippling” can be decreased by the application ofwindows. A window is a filter which decreases the ripples. The window is applied in time-domain: the filter coefficients cn are weighted by factors wn which achieve an extra filtering function.

  29. The resultant windowed filter has transfer function

  30. We have several types of windows: Hamming, von-Hann, or “Hanning,” Blackman, Kaiser. Such filters are available through MATLAB via commands like >> win = hamming(2*r+1); We can then multiply each of the coefficients by these Hamming coefficients: >> c = c.*win’;

  31. The resultant filter coefficients cn will yield a filter with decreased “rippling” at the transition. The frequency plots for the previous filter with a Hamming window applied are shown on the following slide.

  32. The “rippling” is greatly reduced, but the steepness of the frequency rolloff is decreased.

  33. One last problem, is non-realizable: the impulse response has negative terms and the system is non-causal. The system basically responds r samples before the input is applied. We fix this problem by delayingthe impulse response by r samples.

  34. Our equivalent causal (realizable) filter (with delay) transfer function is Thus, h[n] = c-n-r, and the order of the filter is 2r.

  35. In our previous example for r=5, and wc=p/2 our non-realizable filter was The corresponding realizable filter is

More Related