Report

Lecture 23 Filters Hung-yi Lee Filter Types Lowpass filter Bandpass filter wco : cutoff frequency Bandwidth B = wu - wl Highpass filter Notch filter Real World Ideal filter Transfer Function – Rules • Filter is characterized by its transfer function H s = N s D s =K s z1 s z 2 s z m s p1 s p 2 s p n The poles should be at the left half of the s-plane. We only consider stable filter. Given a complex pole or zero, its complex conjugate is also pole or zero. Transfer Function – Rules • Filter is characterized by its transfer function H s = N s D s =K s z1 s z 2 s z m s p1 s p 2 s p n n m :improper filter As the frequency increase, the output will become infinity. n m :proper filter We only consider proper filer. The filters consider have more poles than zeros. Filter Order H s = N s D s =K s z1 s z 2 s z m s p1 s p 2 s p n Order = n The order of the denominator is the order of the filter. order=1 order=4 order=4 Outline • Textbook: Chapter 11.2 Second-order Filter First-order Filters Lowpass Filter Highpass Filter Lowpass Filter Highpass Filter Bandpss Filter Notch Filter First-order Filters Firsr-order Filters H s = N s zero or first order first order D s 0 or 1 zero 1 pole Case 1: Case 2: 1 pole, 0 zero 1 pole, 1 zero H s = K 1 s p H s = K sz s p Firsr-order Filters - Case 1 Lowpass filter H s = K w 1 s p As ω increases Magnitude decrease Phase decrease Pole p is on the negative real axis Firsr-order Filters - Case 1 • Amplitude of the transfer function of the first-order low pass filter Ideal Lowpass filter First-order Lowpass filter Firsr-order Filters - Case 1 • Find cut-off frequency ωco of the first-order low pass filter w At DC Lowpass filter H s = K 0 = K 1 s p 1 | p| Find cut-off frequency ωco such that | p| w co = K 1 | p| 1 2 w co = | p | Firsr-order Filters - Case 2 H s = K sz s p w Zero can be positive or negative |z| | p| Case 2-1: Absolute value of zero is smaller than pole Magnitude is proportional to the length of green line divided by the length of the blue line Low frequency ≈ |z|/|p| Because |z|<|p| The low frequency signal will be attenuated If z=0, the low frequency can be completely block Not a low pass Firsr-order Filters - Case 2 H s = K sz s p w Case 2-1: Absolute value of zero is smaller than pole Magnitude is proportional to the length of green line divided by the length of the blue line High frequency The high frequency signal will pass |z| | p| If z=0 (completely block low frequency) H s = K s s p High pass First-order Filters - Case 2 H s = K s s p • Find cut-off frequency ωco of the first-order high pass filter w = K | jw | w co | jw p | w |p| 2 2 co = K w co = K 2 = 1 2 w co = | p | | j w co | | j w co - p | = K 2 (the same as low pass filter) First-order Filters - Case 2 H s = K sz s p w Case 2-2: Absolute value of zero is larger than pole Low frequency ≈ |z|/|p| Because |z|>|p| The low frequency signal will be enhanced. High frequency: magnitude is 1 The high frequency signal will pass. Neither high pass nor low pass First-order Filters vh 1 H lp s = 1 sC R = 1 1 sRC 1 sC 1 vl 1 H lp j w = w = RC jw 1 Lowpass filter If vh is output Highpass filter 0 = 1 = 0 RC 1 2 w RC RC If vl is output RC 1 s RC 1 sC Consider vin as input = w co = 1 2 (pole) RC s H hp s = 1 H lp s = s 1 RC 0 = 0 = 1 w co = 1 RC (pole) First-order Filters H lp s = vh R R sL R = L s R L R R H lp j w = vl L jw R w = L R w L 2 L 0 = 1 = 0 w co = H hp s = 1 H lp s = 2 s s R L R L (pole) Cascading Two Lowpass Filters V out Vx V in H lp 1 s = H lp s = Vx V in H lp 2 s = H lp 1 s V out Vx H lp 2 s Cascading Two Lowpass Filters V out Vx V in 1 1 H lp s = = sC 1 R1 1 sC 1 sC 2 R2 = 1 1 sC 1 R1 1 sC 2 1 1 s C 1 R 1 C 2 R 2 s C 1 C 2 R 1 R 2 2 1 sC 2 R 2 1 Cascading Two Lowpass Filters V out Vx V in Z eq s The first low pass filter is influenced by the second low pass filter! H lp 1 s = Vx V in = Z eq s Z eq s R1 Cascading Two Lowpass Filters V out Vx V in 1 Z eq s = || R 2 sC 1 sC 2 1 1 R2 sC 1 sC 2 = 1 1 R 2 sC 1 sC 2 Z eq s 1 2 s C 1C 2 2 s C 1C 2 = sC 2 R 2 1 s C 1 C 2 s C 1 C 2 R 2 2 Cascading Two Lowpass Filters V out Vx V in Z eq s H lp s = H lp 1 s H lp 2 s = = 1 Z eq s Z eq s R1 sC 2 1 sC 2 1 1 s R 1C 1 C 2 R 2 R 1C 2 s C 1C 2 R 1 R 2 2 R2 Second-order Filters Second-order Filter H s = N s 0, 1 or 2 zeros D s Second order Must having two poles 2 poles Case 1: No zeros Case 2: One zeros Case 3: Two zeros Second-order Filter – Case 1 Case 1-1 Case 1-2 w w p1 p1 p2 p2 Second-order Filter – Case 1 Case 1-1 Real Poles w The magnitude is l1 The magnitude monotonically decreases. l1 p1 p2 l1l 2 As ω increases l2 l2 K Decrease faster than first order low pass Second-order Filter – Case 1 Case 1-2 Complex Poles w The magnitude is l1 As ω increases, l2 p1 l1 l2 p2 K l1l 2 l1 decrease first and then increase. l2 always increase What will happen to magnitude? 1. Increase 2. Decrease 3. Increase, then decrease 4. Decrease, then increase Second-order Filter – Case 1 Case 1-2 Complex Poles w If ω > ωd l1 l2 p1 wd wd p2 l1 and l2 both increase. The magnitude must decrease. What will happen to magnitude? 1. Increase 2. Decrease 3. Increase, then decrease 4. Decrease, then increase Second-order Filter – Case 1 Case 1-2 Complex Poles l1 p1 wd wd p2 When ω < ωd w w l2 l1 = w d w l2 = w d w 2 2 2 2 Maximize the magnitude K l1l 2 Minimize l1l 2 = 2 wd w 2 2 wd w 2 Second-order Filter – Case 1 Minimize l l = w w w w Minimize f w = w w w w df w = 2 w w 1 w w 2 w w w dw w w 1 w w w w w w = 0 2 2 1 2 2 2 d d 2 2 2 2 d d 2 2 d 2 2 2 w w d w d w 2 2 w d = 0 w wd w 2 = wd w 2 =0 d w w d w 2w = 0 2 w 2 2 d w wd w d 2 d 2 w w d d 2 d 2 d 2 w wd 2 = 0 w d w w d w = 0 2 w = wd 2 2 (maximize) Second-order Filter – Case 1 w = wd 2 2 Lead to maximum The maxima exists when w d w Peaking w p1 p1 wd wd wd wd p2 wd p2 No Peaking wd Peaking Second-order Filter – Case 1 w = wd 2 2 Lead to maximum The maxima exists when w d wd l1 w wd p2 w = w p1 =K l2 Peaking K l1l 2 1 w d w 2 2 w d w 2 2 Assume w = w d2 2 w = K 1 2w 0 = K d 1 wd 2 2 Second-order Filter – Case 1 K H s = s 2 w0 Q sw 2 0 w0 Q p1 , p 2 = w0 Q 2 4 w 02 2 For complex poles p1 w0 wd wd 4 w 02 0 = w0 wd = w0 2 Q wd = w0 1 2Q w0 p2 w0 Q 2 2 1 2 1 4Q 2 Second-order Filter – Case 1 H s = s 2 w0 Q sw jw 2 0 w = w0 = Q times p1 K H jw = K w w0 wd wd w0 Q K w 2 jw w 0 2 j w0 w Q K H jw 0 = w = w0 w0 2 j w0 p2 2 0 2 Q w 0 = K w 2 0 Q 0 = K w0 2 Q times of DC gain Second-order Filter – Case 1 w = w 2 d 2 K H s = s 2 w0 w = K Lead to maximum sw Q For complex poles 2 0 w0 Q = p1 , p 2 = w0 Q w0 Q 2 2 w0 2Q wd = w0 1 2w 4 w 02 2 4 w 02 0 1 1 Q 2 1 4Q 2 d Second-order Filter – Case 1 w = w 2 d 2 H s = s 2 w0 = s w0 2 Q w = w0 1 w = K Lead to maximum K 1 2Q 2 w0 wd = w0 1 2Q 1 2w d 1 4Q 2 Lead to maximum The maximum value is K The maximum exist when Q 1 2 1 2w = 0 . 707 = K d 1 Q w0 2 1 1 4Q 2 Second-order Filter – Case 1 Case 1-1 Real Poles Case 1-2 Complex Poles w w p1 p1 p2 wd wd Q 0 .5 (No Peaking) p2 0 . 707 Q 0 . 5 Which one is considered as closer to ideal low pass filter? K H s = s 2 w0 Q Q 0 .5 s w0 2 Q = 1 Complex poles = 0 . 707 2 (Butterworth filter) Q 0 . 707 Peaking Butterworth – Cut-off Frequency K H s = s 2 w0 s w0 H jw = = 0 = K s 2 = 0 . 707 2 2 Q = Q = 1 2w 0 s w 0 2 K w0 2 w co = K j w 2 w 2w 0 jw w 0 2 K 2 0 w 2 j 2w 0 w 1 K 2 w0 2 w co = w 0 ω0 is the cut-off frequency for the second-order lowpass butterworth filter (Go to the next lecture first) Second-order Filter – Case 2 Case 2: 2 poles and 1 zero Case 2-1: 2 real poles and 1 zero w z1 p 2 p1 w p2 z1 p1 w p 2 p1 z1 Second-order Filter – Case 2 Case 2: 2 poles and 1 zero Case 2-1: 2 real poles and 1 zero w p 2 p1 z1 flat Bandpass Filter Second-order Filter – Case 2 Case 2-2: 2 complex poles and 1 zero w Two Complex Poles p1 -40dB w0 w0 + z1 Zero +20dB p2 | z1 | Second-order Filter – Case 2 Case 2-2: 2 complex poles and 1 zero | z 1 | w 0 -40dB -20dB Two Complex Poles w 0 | z1 | -40dB w0 + +20dB -20dB Zero +20dB | z 1 | w 0 | z1 | w0 | z1 | Second-order Filter – Case 2 Case 2-2: 2 complex poles and 1 zero Highly Selective +20dB -20dB | z 1 |= 0 Two Complex Poles -40dB w0 + w0 Zero +20dB Bandpass Filter | z1 | Bandpass Filter • Bandpass filter: 2 poles and zero at original point H bp ( s ) = K w s s w 0 Q s w 0 2 2 Find the frequency for the maximum amplitude bandpass filter ω0? Bandpass Filter • Find the frequency for the maximum amplitude H bp ( s ) = K H bp ( j w ) = = s s w 0 Q s w 2 2 0 K w 0 Q j w jw 2 w 0 Q j w w K jw Q w0 1 w0Q jw = 2 0 = = w 0 K 2 s w 0 w0 Q s w 0 2 K j w 2 w 0 Q j w K jw Q Q s 1 jw 0 Q w = w0 2 1 w 0 Q jw K w w0 1 jQ w w0 Bandpass Filter • Find the frequency for the maximum amplitude H bp ( j w ) = K w w0 1 jQ w w 0 K a bp (w ) = w w0 1 Q w w 0 2 a bp (w ) is maximized when w = w 0 (Center frequency) The maximum value is K’. 2 a bp ( 0 ) = 0 a bp ( ) = 0 (Bandpass filter) Bandpass Filter a bp (w ) is maximized K a bp (w ) = w0 2 w 1 Q w w 0 w when w = w 0 2 The maximum value is K’. bandpass filter K K / 2 B wl w0 Bandwidth B = ωr - ωl wr Bandpass Filter - Bandwidth B K a bp (w ) = = w0 2 w 1 Q w w 0 2 K 2 2 2 w w0 1 w w = Q2 0 1 2 2 w w 0w w 0 = 0 Q w w0 =2 1 Q w w 0 w0 w 1 = w0 w Q 2 2 w = 1 Q w0 1 2 w 0 4 w 0 Q 2 Four answers? Pick the two positive ones as ωl or ωr Bandpass Filter - Bandwidth B 2 w = 1 w0 Q 1 2 w 0 4 w 0 Q 2 2 1 wr = Q w0 1 2 w 0 4 w 0 Q 2 B = wr wl = w0 Q w = w rw l 2 0 Q measure the narrowness of the pass band Q is called quality factor 2 wl = 1 Q w0 1 2 w 0 4 w 0 Q 2 H bp ( s ) = K = K s s w 0 Q s w 0 2 2 s s Bs w0 2 2 Bandpass Filter H bp ( s ) = K = K s s 2 w 0 2 Q s w0 s s Bs w0 2 2 Usually require a specific bandwidth The value of Q determines the bandwidth. When Q is small, the transition would not be sharp. Stagger-tuned Bandpass Filter Stagger-tuned Bandpass Filter - Exercise 11.64 s H s = K s 2 w1 K = 1600 s sw Q Bandpass Filter Center frequency: 10Hz 2 1 s 2 w2 sw Q w 1 = 10 w 2 = 40 2 2 Bandpass Filter Center frequency: 40Hz We want flat passband. dB Tune the value of Q to achieve that 10 Hz 40 Hz Stagger-tuned Bandpass Filter - Exercise 11.64 H s = K s 2 s s w1 w2 Q s w1 s 2 2 Q K = 1600 s w2 2 w 1 = 10 w 2 = 40 Test Different Q Q=3 Q=1 Q=0.5 Second-order Filter – Case 3 • Case 3: Two poles, Two zeros Case 3-1: Two real zeros Two real poles Two Complex poles w w p1 z1 z1 p2 p1 z2 z2 p2 High-pass Second-order Filter – Case 3 Case 3: Two poles, Two zeros Case 3-2: Two Complex zeros s p 1 s p 2 = s 2 w0 Q w0 p1 w w s w0 2 z1 Fix ω0 Larger Q s z1 s z 2 = Larger θ s 2 w Q s w 2 z2 Fix ωβ Larger Q β Larger θ β p2 Second-order Filter – Case 3 Case 3: Two poles, Two zeros Case 3-2: Two Complex zeros w0 w w0 p1 w w z1 Two poles w0 -40dB Two zeros z2 w +40dB p2 Second-order Filter – Case 3 Case 3: Two poles, Two zeros Case 3-2: Two Complex zeros w0 w s 2 w Q H s = s 2 w0 Q w0 p1 w w s w 2 z1 s w0 2 w 0 = 10, w = 1, Q = Q = 10 z2 High-pass Notch p2 Second-order Filter – Case 3 Case 3: Two poles, Two zeros Case 3-2: Two Complex zeros w w0 w w0 w z1 p1 Two poles w0 -40dB Two zeros w +40dB p2 z2 Second-order Filter – Case 3 Case 3: Two poles, Two zeros Case 3-2: Two Complex zeros w0 w s 2 w Q H s = s 2 w0 Q s w w w w0 2 z1 p1 s w0 2 w 0 = 1, w = 10, Q = Q = 10 Low-pass Notch p2 z2 Second-order Filter – Case 3 Case 3: Two poles, Two zeros Case 3-2: Two Complex zeros w0 = w Q Q w0 = w w p1 z1 Large Q Two poles Two zeros w0 -40dB z2 w +40dB small Qβ p2 Second-order Filter – Case 3 Case 3: Two poles, Two zeros Case 3-2: Two Complex zeros w0 = w Q Q w0 = w w p1 z1 w 0 = w = 10 Q = 100, Q = 10 z2 p2 Second-order Filter – Case 3 Case 3: Two poles, Two zeros Case 3-2: Two Complex zeros w0 = w Two poles Two zeros Q Q w0 = w w p1 z1 small Q w0 w -40dB +40dB Larger Qβ p2 z2 Second-order Filter – Case 3 Case 3: Two poles, Two zeros Case 3-2: Two Complex zeros w0 = w Q Q w0 = w w p1 z1 w 0 = w = 10 Q = 10, Q = 100 Standard Notch Filter p2 z2 Second-order Filter – Case 3 Case 3: Two poles, Two zeros Case 3-2: Two Complex zeros w0 = w s w0 Q H s = s 2 w0 Q w 0 = w z1 Q Q If the two zeros are on the ω axis The notch filter will completely block the frequency ω0 2 w p1 Q = s w0 2 s w0 2 = sw 2 0 s 2 w0 Q 2 sw 2 0 p2 z2 Notch Filter s 2 w0 Q H no s = s 2 w0 Q w no w = w 2 0 2 0 s w0 2 The extreme value is at ω= ω0 s w0 2 no w 0 = w w 0 Q 2 w 0w Q 2 w 2 2 w 2 2 no 0 = 1 Q Q no = 1 (Notch filter) Second-order RLC Filters A v in C v in v out v out B v out v in D v in v out RLC series circuit can implement high-pass, lowpass, band-pass and notch filter. Second-order RLC Filters A v in v out DC (O) Infinity (X) Low-pass Filter B v out v in DC (X) Infinity (O) High-pass Filter Second-order RLC Filters v out w C p1 v in z1 p2 H s = R R sL 1 = sCR sC R s CL 1 2 s = s s 2 R L R L sC Band-pass Filter 1 LC Second-order RLC Filters – Band-pass C v out v in 40pF to 360pF L=240μH, R=12Ω s H s = s s 2 R L R L w0 Q Frequency range Center frequency: w 0 = 1 1 LC w 2 0 f0 = Max: 1.6MHz w0 2 LC = 1 2 LC min: 0.54MHz Second-order RLC Filters – Band-pass C v out v in 40pF to 360pF L=240μH, R=12Ω s H s = s s 2 Frequency range 0.54MHz ~ 1.6MHz R L R L w0 Q w0 = 1 1 LC w 2 0 Q = LC w 0L R w0 Q = R L Q = 1 L R C Q is 68 to 204. Band-pass 1 s v in 1 s Z eq v out s 1 s s 1 s = s 1 s s 2 s V out = V in 1 1 s 1 = || 1 = || s s s s 1 1 s 1 = Z eq 1 Z eq s 1 1 1 1 s s s s 2 = V in s 1 s 1 1 s s 2 = V in s s 3s 1 2 Band-pass 1 s v in 1 v out s H s = s s 3s 1 2 Band-pass Filter V out = V in H s = V out V in = s s 3s 1 2 s s 3s 1 2 w =1 2 0 w0 = 1 B= w0 Q Q = 1 3 =3 Second-order RLC Filters C v out D v out v in v in s H bp s = s s 2 H s = 1 - H bp s R L R L LC 1 s 2 1 LC = s s 2 R L Notch Filter 1 LC Active Filter V in = i Z i Basic Active Filter V out = i Z f -i H s = i 0 0 V in V out V out V in = Z f Zi First-order Low-pass Filter Z R f H s = f = V out = || f sC = Ri Zi R Zi V in Z 1 R iR 1 f sC f R f 1 sC f f R i 1 sR f C f w co = 1 R f C f f First-order High-pass Filter Z H s = f Zi = Z f Zi R Ri V in V out = f 1 sC i sC i R f sC i R i 1 w co = 1 R i C i Active Band-pass Filter Band-pass Filter Active Band-pass Filter H 1 s = = R R i 1 sR f C f R 1 sR C 1 H 2 s = = R H bp s = H 1 s H 2 s = 1 sRC 1 f sC i R f sC i R i 1 sR C 2 sR C 2 1 sR C 2 sR C 1 2 ? Loading H s = v out Z The loading Z will change the transfer function of passive filters. v in Z f Zi v out The loading Z will NOT change the transfer function of the active filter. Z Cascading Filters If there is no loading H s = The transfer function is H(s). V in H s V in One Filter Stage Model V out V in V out Cascading Filters V1 H 1 s V1 1st Filter with transfer function H1(s) H 2 s V 2 V2 2st Filter with transfer function H2(s) Overall Transfer Function: H s = V3 V1 H 1 s H 2 s V3 Cascading Filters H 1 s V1 V1 1st Filter with transfer function H1(s) V 2 = H 1 s V1 V 3 = H 2 s V 2 Z i2 Z o1 Z i 2 H 2 s V 2 V2 V3 2st Filter with transfer function H1(s) V 3 = H 2 s H 1 s V1 H s = V3 V1 Z i2 Z o1 Z i 2 = H 2 s H 1 s Z i2 Z o1 Z i 2 H s = H 2 s H 1 s Cascading Filters V1 H 1 s V1 1st Filter with transfer function H1(s) Z i2 Z o1 Z i 2 H 2 s V 2 V2 2st Filter with transfer function H1(s) H s = H 2 s H 1 s If zero output impedance (Zo1=0) or If infinite input impedance (Zi2=∞) V3 Cascading Filters – Input & Output Impedance Z o s IT VT Z i s Z i s = H s V i VT IT Z o s Vi = 0 Z i s H s V i V T IT Z o s = VT IT H s = H 2 s H 1 s If zero output impedance (Zo1=0) or If infinite input impedance (Zi2=∞) Cascading Filters – Basic Active Filter -i =0 i =0 Z o s = 0 0 0 V in =0 IT VT VT IT =0 Active Notch Filter A B Which one is correct? Active Notch Filter Low-pass Filter High-pass Filter Add Together Homework • 11.19 Thank you! Answer • 11.19: Ra=7.96kΩ, Rb= 796Ω, va(t)=8.57cos(0.6ω1t-31。) +0.83cos(1.2ω2t-85。) vb(t)=0.60cos(0.6ω1t+87。) +7.86cos(1.2ω2t+40。) (ω1 and ω2 are 2πf1 and 2πf2 respectively) • 11.22: x=0.14, ωco=0.374/RC • 11.26(refer to P494): ω0=2π X 6 X 10^4, B= ω0=2π X 5 X 10^4, Q=1.2, R=45.2Ω, C=70.4nF • 11.28(refer to P494): C=0.25μF, Qpar=100, Rpar=4kΩ, R||Rpar=2kΩ, R=4kΩ Acknowledgement • 感謝 江貫榮(b02) • 上課時指出投影片的錯誤 • 感謝 徐瑞陽(b02) • 上課時糾正老師板書的錯誤 Appendix Aliasing Sampling Wrong Interpolation Actual signal High frequency becomes low frequency Phase cos 10 t cos 20 t filter w = 1 w = 90 cos 10 t 2 cos 20 t 2 Table 11.3 Simple Filter Type Lowpass Highpass Bandpass Notch Transfer Function H (s) = H (s) = H (s) = H (s) = Properties a (0 ) = K K w co s w co a (w co ) = K a ( ) = K Ks s w co a (w co ) = K K w 0 Q s 2 K s 2s w0 2 2 2 B = w0 Q a (w 0 ) = KQ w 0 s w 0 Q s w 0 2 2 a (w 0 ) = K s w 0 Q s w 0 2 2 B = w0 Q 98 Loudspeaker for home usage with three types of dynamic drivers 1. Mid-range driver 2. Tweeter 3. Woofers https://www.youtube.com/watch?v=3I62Xfhts9k From Wiki • Butterworth filter – maximally flat in passband and stopband for the given order • Chebyshev filter (Type I) – maximally flat in stopband, sharper cutoff than Butterworth of same order • Chebyshev filter (Type II) – maximally flat in passband, sharper cutoff than Butterworth of same order • Bessel filter – best pulse response for a given order because it has no group delay ripple • Elliptic filter – sharpest cutoff (narrowest transition between pass band and stop band) for the given order • Gaussian filter – minimum group delay; gives no overshoot to a step function. Link • http://www.ti.com/lsds/ti/analog/webench/weben ch-filters.page • http://www.analog.com/designtools/en/filterwizar d/#/type Suppose this band-stop filter were to suddenly start acting as a high-pass filter. Identify a single component failure that could cause this problem to occur: If resistor R3 failed open, it would cause this problem. However, this is not the only failure that could cause the same type of problem!