500 likes | 644 Views
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)
E N D
Engineering 43 Bode PlotsFilters Bruce Mayer, PE Licensed Electrical & Mechanical EngineerBMayer@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 vsf 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
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 Follow May appear on the Next MidTerm Exam, or on the Final Exam
ProtoTypical H(f) for Bode • The 1-”Pole” and 1-”Zero” Xferfcn: • 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
Bode Plot Construction • H(f) in POLAR Form • Then
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| consist of TWO Straight lines • For SMALL f • ForLARGE 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” at102 Hz Straight-Line Approximations 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)')
Bode Plot Example: • Converting to dB form with fB = 300Hz • Note again theCorner • This time at300 Hz • 1885 rads/sec
Near the Corner: • Why the “10”? →
Straight-Line Phase-Angle Plots • The Phase Angle of constant K0 is zero degrees • The phase angle of a 1st order ZERO Xferfcnhas 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 Xferfcnhas 3 straight lines (jf/fBpin 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 φH: • ReCall from the dB development • In this case • Also Recall that for this transfer fcn
Angle, φH, 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, φH, 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 Hin 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 CANCEL EXACTLY • Thus the Frequency, f0, that produces a PURELY Resistive Impedance where VO = VS:
Find Transfer Function Poles • H(f) Denom is quadratic in f
Simplify Transfer Function • Multiply the Transfer Function by 1
Magnitude Response • The response “peakiness” depends on Q • Normalize theIndependent Variable to f/f0to 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, 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 = 377rads/sec)
WhiteBoard: Filter Results • Check the Effectivenessof the Filter Design if • C = 100 µF • L = ??? • Rld = 100 Ω • Filter out 60Hz noise that is 5X the Audio Signal; to whit: Noise Signal
WhiteBoard: Filter Results • Neglecting Phase-Shifts the Output: • The Signal-Amplitude is now 10X the Noise-Amplitude • Plot the Result using MATLAB
% 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
All Done for Today 796 HzBandPassFilter
Engineering 43 Appendix Bruce Mayer, PE Licensed Electrical & Mechanical EngineerBMayer@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
Im Re 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