1 / 14

IIR Filters and Equalizers

IIR Filters and Equalizers. R.C. Maher ECEN4002/5002 DSP Laboratory Spring 2002. IIR Filter Description. We will consider IIR filters with a rational transfer function (M  N):. +. y[n]. x[n]. b 0. Z -1. Z -1. y[n-1]. x[n-1]. -a 1. Z -1. b 1. Z -1. x[n-2]. y[n-2]. b 2. -a 2.

dezso
Download Presentation

IIR Filters and Equalizers

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. IIR Filters and Equalizers R.C. Maher ECEN4002/5002 DSP Laboratory Spring 2002

  2. IIR Filter Description • We will consider IIR filters with a rational transfer function (MN): IIR and EQ R. C. Maher

  3. + y[n] x[n] b0 Z-1 Z-1 y[n-1] x[n-1] -a1 Z-1 b1 Z-1 x[n-2] y[n-2] b2 -a2 IIR Direct Form I • Rational transfer function leads to a direct implementation: IIR and EQ R. C. Maher

  4. x[n] y[n] b0 + + Z-1 -a1 b1 Z-1 -a2 b2 IIR Direct Form II • Re-order feed-forward and feed-back sections: IIR and EQ R. C. Maher

  5. Implementation Issues • Coefficient quantization • Precision usually limited to word size (24 bits on 56300) • Want coefficients to be large in magnitude to use as many significant bits as possible • Roundoff error (least significant bits lost) • Result from big accumulator (e.g., 60 bits) must be stored back as a single word (24 bits) • Roundoff error can accumulate due to recursive (feedback) structure of IIR filters IIR and EQ R. C. Maher

  6. Implementation Issues (cont.) • Overflow error (most significant bits lost) • Occurs when arithmetic result is too large to fit in accumulator or in storage word size • Overflow can linger due to feedback • Requires scaling of the input and output • Coefficient quantization, roundoff error, and overflow error behavior can vary from one filter structure to another: choose wisely… IIR and EQ R. C. Maher

  7. Engineering an IIR filter • Verify filter performance with quantized coefficients • Assess roundoff error by modeling the truncation as a noise source in the filter structure. Determine the transfer function from each roundoff noise source to the output. • Calculate overflow situations by looking for peaks in frequency response from input to each accumulation point in the filter. IIR and EQ R. C. Maher

  8. 2nd-order Sections • Generally implement high-order IIR filters as a sum or cascade of 2nd-order filters. • This reduces the sensitivity of the overall response to the precision of each coefficient • Each 2nd-order filter (biquad) implements two zeros and two poles (real or complex conjugate) IIR and EQ R. C. Maher

  9. 2nd-order Sections (cont.) • High-order polynomial is factored to find poles and zeros • Poles and zeros are grouped in pairs—usually try to group in such a way that minimizes peak gain of each section • If cascaded, 2nd-order sections are usually ordered from lowest gain to highest gain to minimize overflow likelihood • Scaling may be needed for overall response or for each section individually (computation vs. quality) IIR and EQ R. C. Maher

  10. Bilinear Transform • Design algorithms for continuous-time filters are well known, while Nyquist issues make discrete-time IIR filter design somewhat complicated • Concept: use a continuous-time filter design, then transform s-plane poles and zeros to the z-plane • Need: an invertible mapping function between s and z planes IIR and EQ R. C. Maher

  11. Bilinear Transform (cont.) • Mapping function must: • Take j axis in s-plane and map it to unit circle in z-plane (warped frequency response) • Take left half of s-plane and map to interior of unit circle (stable poles remain stable poles) • Have a smooth, monotonic warping • Customary function: IIR and EQ R. C. Maher

  12. Bilinear Transform (cont.) • Inverse mapping is: • Frequency warping: z=ej IIR and EQ R. C. Maher

  13. Bilinear Transform (cont.) • Plan: • Determine required critical frequencies and levels in digital domain, then use bilinear transform to find analog specs • Design continuous-time filter meeting warped specs • Inverse transform to get resulting digital design • Verify, then alter and repeat process as necessary IIR and EQ R. C. Maher

  14. Lab Exercise #4 • MATLAB functions: butter, scope, iirtable • Write IIR filter function using output from iirtable. Use a “do loop” with iterations determined from iirtable. • Verify with file I/O and real time observation • Get working, then consider optimizations • Parametric equalizer (EQ) filter • Tune gain, center freq, and bandwidth • Adjust parameters with debugger and verify IIR and EQ R. C. Maher

More Related