Analogfilters UNSW 2009
Analogfilters UNSW 2009
Analog filters
• Learn how filter characteristics are related to a filter circuit transfer function, its
poles and zeros.
• Learn about first order and second order active and passive filters, and using them
as building blocks to construct higher order filters.
Signals and Systems, 2009 2
• In general, given an input signal r(t), the output of the system is found as
Z ∞
1
y(t) = Y (jω)ejωt dt, Y (jω) = H(jω)R(jω).
2π −∞
The frequency response H(jω) determines how the system modifies the sinusoidal
content of the input signal.
Signals and Systems, 2009 3
• Plots of |H(jω)| and ∠H(jω) versus ω are called the Bode plot.
Bode Diagram
−5
Example The RLC circuit in one of the −10
System: H
Magnitude (dB)
previous examples was shown to have the −15
−20
Frequency (rad/sec): 2
Magnitude (dB): −9.4 System: H
Frequency (rad/sec): 20
−30
−40
using Matlab: 0
>> s=tf(’s’);
Phase (deg)
−90
−2 −1 0 1 2
10 10 10 10 10
Frequency (rad/sec)
Signals and Systems, 2009 4
Frequency axis
• logarithmic scale for ω , i.e., a horizontal distance corresponds to a ratio. The ratio
10 : 1 corresponds to one decade.
Magnitude |H(jω)|
Phase ∠H(jω)
2. Choose a “reference” frequency, which is at least one decade less than the
smallest root or zero, or at least one decade greater than the largest root or zero.
In this example, let ω = 0.1:
√ √
10|j0.1 + 1| 10
20 log10 H(j0.1) = 20 log10 ≈ 20 log10 = 10 dB.
0.1|0.1j + 10| 0.1 × 10
3. Starting from this point, sketch the plot as shown in the figure, following the
following rules:
• The slope must increase by 20dB/decade ×m at a frequency ω = |z|, if the
system has zero at s = z of multiplicity m.
• The slope must decrease by 20dB/decade ×m at a frequency ω = |p|, if the
system has pole at s = p of multiplicity m.
Signals and Systems, 2009 6
15
10
−10
−15
True plot
−20
−25
Corner frequencies
−30
−35
0 1 2
10 10 10
Signals and Systems, 2009 7
For a transfer function that has a pair of complex conjugate poles or zeros, the
procedure is essentially the same. The corner frequencies corresponding to the
complex conjugate poles or zeros are at the resonant frequency ω0 of the poles
(zeros). At this corner frequency the slop changes by ±40 dB/decade (increases at
the zeros, and decreases at the poles).
ω02
For example, for an underdamped system H(s) = 2 ω0 2 , ω 0 > 0,
s + Q s + ω0
Q > 0.5,
20
10
ω02
H(jω) = 0
1
= 2
−20
ω ω
1− ω0 +j ω0 Q
−30
−40
−1 0 1
10 10 10
Frequency
Homework exercise 1
12500(1 + 0.1s)
G(s) =
s(1 + 0.5s)(s2 + 30s + 2500)
s
5(1 + 10 )
= s s 2 s
s(1 + 2 )( 50 ) + 0.6 50 + 1
In order to sketch the magnitude Bode plot, choose a frequency range, say ω from 0.1
rad/sec to 100 rad/sec. Let’s find a point on the low frequency asymptote. Say, for
ω = 0.1 rad/sec,
5
20 log10 |G(0.1j)| = 20 log10 = 20 log10 5 − 20 log10 0.1 ≈ 34 dB.
0.1j
Hence, the low-frequency asymptote is a straight line with a slope of −20 dB/decade
passing through the point ω = 0.1 rad/sec, 20 log10 |G| = 34 dB. This line
continues from ω = 0.1 to the next corner frequency of ω = 2 rad/sec.
The slope of the asymptotic Bode plot will change as ω increases past each corner
frequency.
At ω = 2 rad/sec (pole) the slope decreases by −20 dB/decade and becomes −40
dB/decade. Then, at ω = 10 rad/sec (zero) the slope increases by 20 dB/decade, and
finally decreases by −40 dB/decade at ω = 50 rad/sec (pair of complex poles).
Signals and Systems, 2009 11
40
30
20
Asymptotic Bode plot
10
|G(j ω)|
0
Actual Bode plot
10
-10
20log
-20
-30
-40
-50
pole zero 2 poles
-60
-1 0 1 2
10 10 2 10 50 10
Frequency ω , rad/sec
Signals and Systems, 2009 12
10kΩ 1kΩ
Homework exercise 2
Sketch an asymptotic magnitude Bode plot of vin
the frequency response of the circuit 1µF 1µF
−
vout
+
The transfer function is
Corner frequencies 100 rad/sec (zero) and 1000 rad/sec (pole). Choose the frequency
range from 10 rad/sec to 10000 rad/sec.
10
0
20 log10 |G(jω)|, dB
−5
−10
−15
−20
−25
−30
1 2 3 4
10 10 10 10
Frequency ω, rad/sec
Signals and Systems, 2009 14
Filters
Filter is a system that shapes or modifies the frequency content of a signal or waveform
to suppress or amplify some parts of the input spectrum.
Terminology:
Ideal Filters
Ideally, it is desired that the harmonics of the input spectrum with frequencies in the
filter pass band pass through the filter unmodified, and the harmonics with frequencies
with the frequencies in the stop band are suppressed completely.
|H(jω )|
• Low-pass filter: Components of frequency ω < ωc 1
pass unchanged through the filter, components of
frequency ω > ωc are blocked. The frequency ωc
is the cutoff frequency.
ωc ω
The cutoff frequency separates the pass-band from the stop-band. The output of the
filter contains only harmonics whose frequencies are in the pass-band.
|H(jω )|
|H(jω )|
1
• Band-pass filter: Only components of frequency
ωc1 < ω < ωc2 pass unchanged through the fil-
ter, all other components of the signal are blocked.
ωc ωc ω
1 2
|H(jω )|
1
• Band-stop filter: Components of frequency ωc1 <
ω < ωc2 are blocked. All other components of the
signal pass unchanged through the filter.
ωc ωc ω
1 2
As we have seen, the impulse response of an ideal filter is given by a sync function, or
is constructed using a sync function. Therefore, ideal filter are non-causal and cannot
be realized in real-time.
Signals and Systems, 2009 17
1
|H(jωcutoff )| = √ · max |H(jω)| ≈ 0.707 · max |H(jω)|.
2 ω ω
In circuit theory terms, in the pass-band, the average power delivered to a load is at
least 50% of Pmax .
Signals and Systems, 2009 18
20 log10 k
kωc
Hlp (s) = , −5
s + ωc
kωc −10
|Hlp (jω)| = p ,
2
ω + ωc 2
−20
0 1
10 10
frequency, rad/sec (log scale)
kωc k
p = √ .
2 2
ω + ωc 2
This gives that the cutoff frequency equals the corner frequency ωc .
Signals and Systems, 2009 19
20 log k
1st order HP filter:
ks 3dB=20 log
10
0.707
Hhp (s) = ,
s + ωc −5
kω
|Hhp (jω)| = p ,
2
ω + ωc2 −10
the gain of the filter in the high cutoff frequency = corner frequency ωc
frequency band.
−20
0 1
10 10
frequency, rad/sec (log scale)
kω k
p = √ .
2 2
ω + ωc 2
This again gives that the cutoff frequency equals the corner frequency ωc .
Signals and Systems, 2009 20
Transfer function is R
1 1/(RC)
H(s) = = .
RCs + 1 s + 1/(RC) vin +
+ v
C out
1 − -
The frequency response H(jω) = .
jRCω + 1
1
The cutoff frequency ωc = RC , the DC gain k = 1 (cannot be adjusted!)
R R/L
Transfer function is H(s) = = . L
Ls + R s + R/L +
+ R
The cutoff frequency ωc = R − vin v
L , the DC gain k = 1 - out
(cannot be adjusted either!)
Read more about RL, RC low-pass filters in the text by Nilsson and Reidel.
Signals and Systems, 2009 21
R
Transfer function is
RCs s + v -
H(s) = = . out
RCs + 1 s + 1/(RC)
vin + C
jRCω −
The frequency response H(jω) = .
jRCω + 1
1
The cutoff frequency ωc = RC , the gain at large frequencies ≈ k = 1.
Transfer function is
vout
+ -
Ls s
H(s) = = .
L
Ls + R s + R/L
The cutoff frequency ωc = R + R
L, − vin
the gain at large frequencies ≈ k = 1.
0.9
0.5
ζ ). 0.1
0
0 1
10 10
Filter circuits are designed by choosing the values of prototype circuit components to
match required values of k , w0 , and Q (the coefficient matching technique).
Signals and Systems, 2009 23
kω02 kω02
Low-pass
s2 + ωQ0 s + ω02 ω02 − ω 2 + j ωQ0 ω
ks2 −kω 2
High-pass
s2 + ωQ0 s + ω02 ω02 − ω 2 + j ωQ0 ω
k ωQ0 s jk ωQ0 ω
Band-pass ω0
s2 + Qs + ω02 ω02 − ω 2 + j ωQ0 ω
k(s2 + ω02 ) k(ω02 − ω 2 )
Band-stop
s2 + ωQ0 s + ω02 ω02 − ω 2 + j ωQ0 ω
1 1
The quality factor Q = 2ζ and the damping ratio ζ= 2Q determine the shape of the
frequency response. For an overdamped stable system, 0 < Q < 0.5 and ζ > 1. For
an underdamped stable system, Q > 0.5 and ζ < 1.
Signals and Systems, 2009 24
Q=2
Gain |H(jω)|
Q=1.5
Q=1
k
Q=0.707
(second order
0.707 k Butterworth filter)
Q=0.5
ω0
Frequency, rad/sec
The cut-off frequency is determined by Q and ζ and is found by solving the equation:
2 ω04 1
|Hlp (jω)| = ω02 2
= .
(ω02 − ω)2 + 2
Q2 ω
Signals and Systems, 2009 25
Usually it is desired to have a maximally flat frequency response, that ensures a better
bandwidth without having an unwanted resonance.
LP filters that have maximally flat frequency response are called Butterworth filters.
The second order Butterworth LP filters have the transfer function of the form
kω02 k
√ 2
= 2 √ .
2
s + ω0 2s + ω0 s
ω0 + 2 ωs0 + 1
Q=2
Gain |H(jω)| Q=1.5
Q=1
k
0.707k
Q=0.707
Q=0.5
ω0
Frequency, ω, rad/sec
The cut-off frequency is determined by Q and ζ and is found by solving the equation:
2 ω4 1
|Hhp (jω)| = ω02 2
= .
(ω02 − ω)2 + 2
Q2 ω
Signals and Systems, 2009 27
The transfer function of the resulting filter is the product of the transfer functions:
kωcL ks
H(s) = HLP (s)HHP (s) =
s + ωcL s + ωcH
k 2 ωcL s
= 2 .
s + (ωcL + ωcH )s + ωcL ωcH
• The resulting transfer function has two real poles at s = −ωcL , s = −ωcH .
Hence, the bode plot has two corner frequencies at ω = ωcL , ω = ωcH .
√
• The centre frequency of the filter is ω0 = ωcL ωcH (ie, the frequency in the
centre of the passband on the Bode plot).
Signals and Systems, 2009 28
The Bode plot of a broadband bandpass filter is the sum of the Bode plots of its LP and
HP components
0 0
−5 −5
−10
−10
−15
−15
−20
−20
−25
−25
−30
−30
−35
−45 −40
−2 −1 0 1 2 3 4 −2 −1 0 1 2 3 4
10 10 10 10 10 10 10 10 10 10 10 10 10 10
kωcL ks
H(s) = HLP (s) + HHP (s) = +
s + ωcL s + ωcH
ks2 + 2kωcL s + kωcL ωcH
= 2 .
s + (ωcL + ωcH )s + ωcL ωcH
• The filter has two real poles at s = −ωcL , s = −ωcH , and two corner
frequencies are at ω = ωcL , ω = ωcH .
√
• The centre frequency of the filter is ω0 = ωcL ωcH .
Signals and Systems, 2009 30
5 5
−5 −5
−10 −10
−15 −15
−20 −20
−25
ω =100 rad/s −25
ω =2 rad/s
ω =1 rad/s cH ω =1 rad/s cH
cL cL
−30 −30
−35 −35
−2 −1 0 1 2 3 4 −2 −1 0 1 2 3 4
10 10 10 10 10 10 10 10 10 10 10 10 10 10
Same drawbacks:
• The gain in the stop band increases as ωcL − ωcH reduces, and is more difficult
to predict.
Signals and Systems, 2009 31
Using transfer functions with complex conjugate poles gives better control over the
bandwidth through higher quality factors Q.
k ωQ0 s
Band-pass filter ω0 2 ;
s2 + Qs + ω0
k(s2 + ω02 )
Band-stop filter .
s2 + ωQ0 s + ω02
Signals and Systems, 2009 32
k
Q=0.5
• The maximum gain is at
ω = ω0 :
0.707k max |H(jω)| = k,
ω
Q=0.707
• The cutoff frequencies
Gain |H(jω)|
r 2
ω0 ω0 ω0 √
ωc1,c2 = ± 2Q + 2Q + ω02 , BW = Q, ω0 = ωc1 ωc2
Signals and Systems, 2009 33
min |H(jω)| = 0,
ω
0.707k
• The cutoff frequencies
ωc1 , ωc2 are found
Gain |H(jω)|
Bandwidth
from the equation
k
|H(jω)| = √
2
• The width of the stop
band:
ω1 ω0 ω2
Frequency, ω, rad/sec SB = ωc2 − ωc1
r 2
ω0 ω0 ω0 √
ωc1,c2 = ± 2Q + 2Q + ω02 , SB = Q, ω0 = ωc1 ωc2 .
Signals and Systems, 2009 34
• Bandpass and bandstop filters are implemented without using inductors. Such
circuits are smaller in size and do not induce electromagnetic noise.
• Active filter circuits provide control over the filter gain that is not available in the
case of passive filter circuits.
• Connecting a resistive load at the output of the passive filter modifies its cutoff
frequency and pass-band due to loading. This is not the case with active filters due
to the properties of opamps.
Signals and Systems, 2009 35
C
The transfer function is
Rf Cs s
H(s) = = . +
Rf Cs + 1 s + 1/(Rf C) vin +
− Rf vout
The cutoff frequency is ωc = R 1C . -
f
C cutoff frequency
1
vin R
1 R2 ωc = R2 C ,
− maximum gain
vout R2 /R1 R2
Low-pass, + − |k| = R1
kωc 1 + R2 Cs
s + ωc
cutoff frequency
1
ωc = R1 C
vin R maximum gain
1 C R2 R2 Cs R2
High-pass, − − |k| = R1
ks
vout 1 + R1 Cs
+
s + ωc
Signals and Systems, 2009 37
Example
40
20log10|G(jω)|
20 dB/decade
25
Find R1 , R2 and C to match the required G(s). Using the table, we obtain the
relationship between components
1 R2
ωc = = 500 rad/s, k= = 50
R1 C R1
Let C = 1 µF, then R1 = 2 kΩ, R2 = 100 kΩ.
Signals and Systems, 2009 39
The transfer function of the resulting filter is the product of the transfer functions:
−s RF
−ωcL
H(s) = HL (s)HP (s)HI = −
s + ωcH s + ωcL
R1i
−kωcL s
= 2 .
s + (ωcL + ωcH )s + ωcL ωcH
√
Real poles at s = −ωcL , s = −ωcH , centre frequency is at ω0 = ωcL ωcH .
Signals and Systems, 2009 40
CL
The parallel design gives a
Low-pass stage
bandstop filter. R1L R2L
− R1i
+ A
RF
vin
R1i −
B
CH R2H + vout
−
R1H
+ Summing amplifier
The transfer function is
High-pass stage
−ωcL −s RF
H(s) = (HL (s) + HP (s))HI = + −
s + ωcL s + ωcH R1i
RF s2 + 2ωcL s + ωcL ωcH
= · 2 .
R1i s + (ωcL + ωcH )s + ωcL ωcH
√
Real poles at s = −ωcL , s = −ωcH , the centre frequency is at ω0 = ωcL ωcH .
Signals and Systems, 2009 41
Using transfer functions with complex conjugate poles gives better control over the
bandwidth through higher quality factors Q.
2C
As an example, consider a common
positive-feedback second-order active
bandstop filter known as the Sallen-Key R R v2
+
circuit. The circuit transfer function is v3
vin
−
k(s2 + ω02 ) v1 vout
H(s) = 2 ω0 2 ;
s + Q s + ω0 C C
(A-1)R0
1 1 R/2
R0
ω0 = , Q= , k = A.
RC 4 − 2A
A is the gain of the noninverting amplifier; i.e., A > 1. Also, for stability we need
A < 2.
Signals and Systems, 2009 42
A=1.9
• Changes in A do not affect 5
A=1
• The gain in the pass band −5
back resistor.
−20
−40
5 6 7
10 10 10
Signals and Systems, 2009 43
elliptic filter
0 Butterworth filter
−10
−50
−60
0 1 2 3 4
10 10 10 10 10
Frequency ω, (rad/sec)
Signals and Systems, 2009 44
1
|Hn (jω)| = p , 1
1 + (ω/ωc )2n
0.8
Magnitude
0.6
±1
0.4
RC filter
Dn (s/ωc ) 0.2
4th order
Butterworth filter
0
−1 0 1
Example Design the third order Butterworth filter with a cutoff frequency of 500
rad/sec.
Solution From the table, Dn (s) = (s + 1)(s2 + s + 1), and since the desired cutoff
frequency is 500 rad/s, the desired filter must have a transfer function
1 k2 5002 k1 500
H(s) = s s 2 s = 2 · .
( 500 + 1)(( 500 ) + 500 + 1) (s + 500s + 5002 ) (s + 500)
k1 , k2 are constants that must be chosen so that k1 k2 = 1.
Signals and Systems, 2009 46
k2 5002
To obtain H2 (s) = s2 +500s+5002 , we have to set
1 1
ω0 = = 500, Q = = 1, k2 = A = 2.
RC 3−A
R
Choose RA = RB = 20 kΩ, then the condition A = 1 + RA = 2 is satisfied. Also,
B
choose R = 20 kΩ, C = 0.1 µF to achieve ω0 = 500 rad/s.
Signals and Systems, 2009 47
R2 1 1
k1 = = = 0.5, ωc = = 500,
R1 k2 R2 C
Components R1 = 40 kΩ, R2 = 20 kΩ, C = 0.1 µF meet these requirements.
Signals and Systems, 2009 48
2 × 5002 −250
H(s) = 2 · .
s + 500s + 5002 s + 500
0.1uF
0.1uF
+
vin 20k 20k
−
40k 20k
0.1uF
−
vout
20k +
20k