Chapter 7. Filter Design Techniques 7.1 Introduction - Digital Filter Design 7.2 IIR Filter Design by Impulse Invariance 7.3 IIR Filter Design by Bilinear Transformation 7.4 FIR Filter Design by Windowing 7.5 Kaiser Window based FIR Filter Design 7.6 Approximation based Optimal FIR Filter Design BGL/SNU
1. Introduction -- Digital Filter Design (1) Frequency selective filters : spectral shapers lowpass highpass bandpass bandstop (2)Filter Design Techniques IIR : - mapping from analog filters - impulse invariance FIR: - windowing - equiripple design BGL/SNU
In some IIR filter design (3)Filter Specification(LPF) In some IIR filter design 1 2 3 1 2 3 BGL/SNU
2. IIR Filter Design by Impulse Invariance (1) Design Concept - Utilize existing analog filter design technique - Convert analog impulse response into digital impulse response h[n] by taking samples - Take Then by fundamental sampling property, we get - If analog filter were bandlimited, Then BGL/SNU
- But the issue is that the above assumption is not likely, (2) Aliasing Problem - But the issue is that the above assumption is not likely, so aliasing is inevitable in reality aliasing Therefore this design technique is useful only when designing a narrowband sharp lowpass filters BGL/SNU
(3) Parameter Conversion - Let the analog filter has the partial-fraction expansion - After sampling, h [ n ] = T h (nT ) = d c d Therefore, pole at in is mapped to Pole at BGL/SNU
* Impulse Invariance Filter Design Procedure 1) Given specification in domain. 2) Convert it into specification in domain 3) Design analog filter meeting the specification 4) Convert it into digital filter function H(z) by putting [ 5) Implement it in 2nd order cascade form] BGL/SNU
Design Example 1 2 * Choose Td=1 3 BGL/SNU
* You plot the pole locations in the z-plans! 4 * You plot the pole locations in the z-plans! BGL/SNU
3. IIR Filter Design by Bilinear Transformation (1) Design Concept - s-plane to z-plane conversion any mapping than maps stable region is s-plane (left half plane) to stable region in z-plane (inside u.c) ? or bilinear transform! * Td inserted for convention may put to any convenient value for practical use.
(2) Properties
* IIR Filter Design Procedure Given specification in digital domain Convert it into analog filter specification Design analog filter (Butterworth, Chebyshov, elliptic):H(s) Apply bilinear transform to get H(z) out of H(s) 1 2 3 4 3 2 4 1
Design Example (Butterworth Filter) Given specification 1 2 Specification Conversion (Set Td=1) Butterworth filter design 3 N c j H 2 ) / ( 1 | W + =
Bilinear Transform 4
*Comparison of Butterworth, Chebyshev, elliptic filters -Filter equations 1 Butterworth filter B Chebyshev filter (type I) C 1 Chebyshev polynomial
*Comparison of Butterworth, Chebyshev, elliptic filters (Cont’d) Chebyshev filter (type II) 1 Elliptic filter E 1 Jacobian elliptic function
*Comparison of Butterworth, Chebyshev, elliptic filters: Example -Given specification -Order Butterworth Filter : N=14. ( max flat) Chebyshev Filter : N=8. ( Cheby 1, Cheby 2) Elliptic Filter : N=6 ( equiripple) B C E
-Pole-zero plot (analog) B C1 C2 E -Pole-zero plot (digital) B C1 C2 E (14) (8)
-Magnitude -Group delay C1 B B E C1 E C2 C2
4. FIR Filter Design by Windowing (1) Design Concept - Given a desired frequency response evaluate - Then, is the desired filter coefficients. However, is infinitely long, so not practical. Therefore, take a finite segment of , or such that the resulting frequency spectrum fall in the given specification. This process of getting out of is called Windowing
(2) Rectangular Windowing
W ( e j ( w ) )
But M cannot improve this. (due to Gibb’s phenomena). (3) Design Point e ( w ) : depends on the attenuation of the peak sidelobe of W ( e j w ). But M cannot improve this. (due to Gibb’s phenomena). Therefore, once a specific window is given, is fixed. e ( w ) D w : depends on the width of main lobe of W ( e j w ). This can be improved by increasing M.
(4) Commonly Used Windows BGL/SNU
BGL/SNU
Frequency Spectrum of Windows (a) Rectangular, (b) Bartlett, (c) Hanning, (d) Hamming, (e) Blackman , (M=50) BGL/SNU
5. Kaiser Window based FIR Filter Design (1) Design Concept ( I : 0th order modified Bessel function) targets at limited duration in time and energy concentration at low frequency - compromisable. (choose appropriate ) Performance comparable to Hamming window ( when ) BGL/SNU
Frequency Spectrum of Kaiser Window (a) Window shape, M=20, (b) Frequency spectrum, M=20, (c) beta=6 BGL/SNU
(2) Determination of Filter Order ( Kaiser, 1974 ) ① ② ③ BGL/SNU
- Design Example : ① ② ③ ④ (Note)
BGL/SNU
6. Approximation based Optimal FIR Filter Design (1) Design Concept - Linear phase filters possess the property - More Generally, constant delay filters have the expression BGL/SNU
- Approximation error BGL/SNU
- Approximation ( Chebyshev) BGL/SNU
(2) Type I Lowpass Filter case - desired : - approximation - weighting BGL/SNU
- Error function
(3) Type II Lowpass Filter case - desired (original) : - approximation BGL/SNU
- Weighting (modified) - Desired (modified) - error function BGL/SNU
BGL/SNU
(4) Alternation Theorem BGL/SNU
BGL/SNU
BGL/SNU
(5) Parks-McClellan Algorithm ① ② ③ ④ BGL/SNU
Remez Exchange Algorithm (1934) (multiple exchange) ⑤ Remez Exchange Algorithm (1934) (multiple exchange) ① ② BGL/SNU
③ BGL/SNU
④ ⑤ ⑥ BGL/SNU
Selection of new extrema BGL/SNU
Remez Exchange Algorithm Initial guess of (L+2) extremal frequencies Remez Exchange Algorithm Calculate the optimum On extremal set Interpolate through (L+1) Points to obtain Ae(ej) Best approximation Calculate error E() And find local maxima Where | E()|>= Unchanged Check whether the Extremal points changed Changed More than (L+2) extrema? Yes Retain (L+2) Largest extrema No BGL/SNU
Design Examples ① Kaiser, (1974) BGL/SNU
DSP Sample & Hold Comp. Reconst. filter ② DSP Sample & Hold Comp. Reconst. filter BGL/SNU
BGL/SNU
H.W. of Chapter 7 Due 11/17 (Mon.) [1] Design a IIR lowpass filter whose specification is the same as that given in Example 7.3 (page 454) except the passband and stopband edges are shifted to 0.7pi and 0.8pi respectively, using bilinear transform technique. Text : [2] 7.2 [3] 7.3 [4] 7.17 BGL/SNU
H.W. of Chapter 7 Due 11/24 (Mon.) [1] Design a Length-21 FIR Filter Use the MATLAB command h=remez(20, [0,0.4,0.5,1], [1,1,0,0]) to design a length-21 filter with a passband from 0 to wp=0.4pi and a stopband from ws=0.5pi to pi with a desired response of 1 in the passband and zero in the stopband. Plot the impulse response, the zero locations, and the amplitude response. How many “ripples” are there? How many extremal frequencies are there (places where the ripples are the same maximum size)? How many “small ripples” are there that do not give extremal frequencies, and if there are any, are they in the passband or stopband? Are there zeros that do not contribute directly to a ripple? Most zero pairs off the unit circle in the z-plane cause a maximum-size ripple in the passband or stopband. Some cause only a “small ripple,” and some cause no ripple. Text : [2] 7.28 [3] 7.23 [6] 7.36 BGL/SNU