Licensed Electrical & Mechanical Engineer BMayer@ChabotCollege.edu Engineering 43 Bode Plots Filters Bruce Mayer, PE Licensed Electrical & Mechanical Engineer BMayer@ChabotCollege.edu
Outline: Bode Plots A full Bode DIAGRAM consists of two Separate Plots |H(f)| (in dB) vs. f in Hz (or ω in rads/S) H(f) in Degrees vs f in Hz (or ω in rads/S) Recall: ω = 2π∙f “Poles” & “Zeros” in H(f) with one or the Other A “Pole” Frequency, fBp, causes |H|→∞ A “Zero” Frequency, fBz, causes |H| →0 Named after Hendrik W. Bode
UnGraded HW Assignment Students are asked to Work Thru, BY HAND, All the Complex Algebra that follows in the H(f) developments UNDERSTANDING how to Cast Transfer Functions into STANDARD Form is Crucial to Bode Plotting Some of what Follows May appear on the Next MidTerm Exam, or on the Final Exam
ProtoTypical H(f) for Bode The 1-”Pole” and 1-”Zero” Xfer fcn: Then The “dB” Magnitude And the Phase Angle
Bode Plot Construction 𝑥 𝑦 Consider a Transfer Function with one “pole”, and one “zero” K ≡ CONSTANT First, put the Transfer Function into STANDARD FORM K, fBz, fBp are all constants. “Pole” implies that under some circumstances (fBp – jf) could equal zero producing a vertical Asymptote. “Zero” implies that under some circumstances (fBz – jf) could equal zero producing H(f) = 0
Bode Plot Construction H(f) in POLAR Form Then Since in Std Form x=1 it is usually not shown in the aTan calcs 𝑦 𝑥
Bode Plot Construction Bode Magnitudes are typically plotted in deciBels. So from the last Slide
Magnitude Equation Examine the dB Magnitude Equation 20logK0 is a Constant Positive for K0 > 1 Zero for K0 = 1 Negative for K0 < 1 If K0 = 2, then f=0:10:10000; Mag = 20*log10(2)*ones(1,length(f)); semilogx(f,Mag, 'LineWidth',3), grid axis([10 10000 -20 10]) ylabel('Mag_{dB}') xlabel('f(Hz)')
Straight-Line Magnitude Plots An Approximate plot of ±20log|1+jf/fB| consists of TWO Straight lines For SMALL f For LARGE f On a log Scale for f>fB 20log|1+jf/fB| is a Straight-Line with a slope of 20dB/decade This Sloped-Line Intersects the 0dB axis at f = fB Thus fB is often called the CORNER FREQUENCY on a Bode Plot
Bode Plot Example: Taking fBz = 100 Hz, approximate |H(f)| Note the “Corner” at 102 Hz Note the 40db Increase over 102 to 104 → 20dB/decade • (10/100)2 = 1% of 1 • (1000/100)2 is 100 times of 1 f = logspace(0,4,500); Mag = 20*log10(abs(1+j*f/100));; semilogx(f,Mag, 'LineWidth',2), grid axis([1 10000 -10 50]) ylabel('Mag_{dB}') xlabel('f (Hz)') Straight-Line Approximations
Bode Plot Example: Converting to dB form with fB = 300Hz Note again the Corner This time at 300 Hz 1885 rads/sec
Near the Corner: Why the “10”? →
Straight-Line Phase-Angle Plots Plot The phase angle of a 1st order ZERO Xfer fcn of this form 𝑥 𝑦
Straight-Line Phase-Angle Plots The Phase Angle of constant K0 is zero degrees The phase angle of a 1st order ZERO Xfer fcn has 3 straight lines (jf/fBz in numerator) 1. For values of f = fBz, 45° point (by α = atan[1/1]) 2. For values of f>=10 fBz, it is a straight line at 90° (α = atan[10/1] ≈ 90°) 3. For values of f<=0.1fBz, it is a straight line at 0° (α = atan[0.1/1] ≈ 0°) 4. For values of 0.1fBz <= f <= 10fBz, it is a straight line with a slope of 45°/decade The phase angle of 1st order POLE Xfer fcn has 3 straight lines (jf/fBp in denominator) 1. For values of f = fBp, −45° point (by −β = −atan[1/1]) 2. For values of f>=10 fBp, it is a straight line at −90° (−β = −atan[10/1] ≈ − 90°) 3. For values of f<=0.1fBp, it is a straight line 0° ° (−β = −atan[0.1/1] ≈ 0°) 4. For values 0.1fBp <= f <= 10fBp, it is a straight line with a slope of −45°/decade The approximate phase angle of −20 log(f/fB) is a straight line having a slope of −45°/decade that intersects the 0 degree axis at f=0.1fB, and intersects the −90° line at f=10fB
Example 𝝓 𝑯 : ReCall from the dB development In this case Also Recall that for this transfer fcn form
Angle, 𝝓 𝑯 , Approx:
Angle, 𝝓 𝑯 , Exact: f = logspace(-1,4,500); a = atand(f/10); b = atand(f/100); angj = 90*ones(1,length(f)); q = a - angj -b; semilogx(f,a, f,-b, f,-angj, f,q, 'LineWidth',2), grid axis([0.1 10000 -100 100]) ylabel('\phi_{H} (°)') xlabel('f (Hz)')
Angle, 𝝓 𝑯 , Exact by: (31.26 Hz, −35.10°) f = logspace(-1,4,500); h = 2*(1+j*f/10)./((j*f).*(1+j*f/100)) a=angle(h); deg=a*180/pi; [degmax, Nmax] = max(deg); fmax = f(Nmax); semilogx(f,deg, fmax, degmax, '*', 'LineWidth',3), grid axis([0.1 10000 -90 -30]) ylabel('\phi_{H} (°)') xlabel('f (Hz)') fmax degmax
Series LCR Analysis With phasor analysis, this circuit is readily analyzed Use Loop+Ohm
Second Order Transfer Function So we have: To find the poles/zeros, put H in Standard form: One zero at DC frequency (f=0) can’t conduct DC due to capacitor
Resonance For the Series Resonant ckt at Right the Series Impedance: At the “Resonant” Frequency, f0,The imaginary impedances ADD to ZERO EXACTLY Thus the Frequency, f0, that produces a PURELY Resistive Impedance where VO = VS:
Find Transfer Function Poles At Resonance H(f) Denom is quadratic in f f0 is the RESONANT FREQUENCY at which the series impedance is purely resistive. Qs is the Quality-Fraction → ZL/ZR = ZC/ZR
𝑸 𝒔 Complex Algebra For the Last Equation
Simplify Transfer Function Multiply the Transfer Function by 1 0 at 𝑓= 𝑓 0
Magnitude Response The response “peakiness” depends on Q Normalize the Independent Variable to f/f0 to Plot →
BandWidth ReCall the Half-Power Frequency fB At fB: The Series RLC Circuit has TWO half-power Frequencies for any Given value of Q: fL and fH The difference Between the Lo & Hi ½-Power Frequencies is defined as the BANDWIDTH, B
BandWidth Formally Recall the H(f) Then |H(f)|: At the ½-Power Level Frequency fB: Thus Or for fB = fL & fH
BandWidth With Enough Algebra; B Note that |H(f)| may not be symmetrical about f0 Thus for QS >> 1 approximate:
Parallel Resonance Consider the Parallel ckt at Right The Equivalent Parallel Impedance At Resonance, f0, the imaginary Impedances Cancel Then f0: The Quality Factor is the ratio of ZR/ZL
Parallel Resonance Using QP in the Equivalent Impedance expression find And vout by Ohm in Frequency Domain With the previous Bandwidth Definition The H vs f plot
WhiteBoard Work Show that for Series Resonant Ckt
WhiteBoard Work Design a NOTCH Filter to remove 60Hz “Power Line” Hum from an Audio Circuit The Audio Circuit has an equivalent Load, Rld that connects to the Filter Find L, R & C for this passive Filter Design Want |H(f)| = 0 for: f0 = 60 Hz (ω0 = 377 rads/sec) Want w0 = 377 rad/s OR want f0 = 60Hz
WhiteBoard: Filter Results Check the Effectiveness of the Filter Design if C = 100 µF L = ??? Rld = 100 Ω Filter out 60Hz noise that is 5X the Audio Signal; to whit: L = 70.4 mH Noise Signal
WhiteBoard: Filter Results Neglecting Phase-Shifts the Output: The Signal-Amplitude is now 10X the Noise-Amplitude Plot the Result using MATLAB
WhiteBoard: Filter Results
MATLAB Code % Bruce Mayer, PE % ENGR43 • 17Jul11 % Lec6b_Filter60_1107.m % Rld = 100; L = 70e-3;, C = 100e-6; H = @(w) Rld*(1-w.^2*L*C)/((Rld*(1-w.^2*L*C) + j*w*L)); H60 = H(60*2*pi); % 60Hz = 377 rad/sec H1000 = H(1000*2*pi); % 1000 Hz = 6238 rad/sec Vo1 = H60*1; Vo2 = H1000*0.2; Vm1 = abs(Vo1); Vm2 = abs(Vo2); % t in mSec t = linspace(0,25,1500); % Calc the INput vin1 = 1*cos(60*2*pi*t/1000); vin2 = 0.2*cos(1000*2*pi*t/1000); vintot = vin1 + vin2; % Calc the OUTput vo1 = Vm1*cos(60*2*pi*t/1000); vo2 = Vm2*cos(1000*2*pi*t/1000); votot = vo1 + vo2; plot(t, vintot, t, votot, 'LineWidth',3), grid Filterlegend = legend('vin(t)','vo(t)'); xlabel('t (mS)'), ylabel('vin, vo (V)') MATLAB Code
796 Hz BandPass Filter All Done for Today http://www.enzim.hu/~szia/cddemo/edemo4.htm
Licensed Electrical & Mechanical Engineer BMayer@ChabotCollege.edu Engineering 43 Appendix Bruce Mayer, PE Licensed Electrical & Mechanical Engineer BMayer@ChabotCollege.edu
WhiteBoard Work Design a NOTCH Filter to remove 60Hz “Power Line” Hum from An audio Circuit The Audio Circuit has an equivalent Load, Rld to connect to the Filter Find L & C for this passive Filter Design
Check Rejection for Rld = 100Ω
Poles of the Transfer Function The “f” Roots for the DeNominator Poles are complex conjugate frequencies The QS parameter is called the “quality-factor” or Q-factor QS is an important Parameter Re Im
Obsolete – 20Mar12