special notes: filter design methods spectral power responses
TRANSCRIPT
Page 1
Special Notes: Filter Design Methods
Spectral Power Responses
For jwTjwTjwT exp
What is jwT
Magnitude (must be the same!):
N
n n
n
n
M
m m
R
Q
i i
w
w
w
w
p
ww
z
w
KjwT
1
222
1
2
1
2
211
1
Phase:
N
n
n
n
n
M
m m
Q
i i
w
w
w
w
ap
waR
z
wajwT
12
111
2
tantan2
tan
N
n
n
n
n
M
m m
Q
i i
w
w
w
w
ap
waR
z
wajwT
12
111
2
tantan2
tan
Therefore jwTjwT and 0 jwTjwT
Then, what is jwTjwTjwTjwTjwTjwT expexp
or 2jwTjwTjwT
This is a power term (notice the square), so we use 10*log to create decibels. It is the same result!! Note, this works for (s,-s) too!!
2sTsTsT
This is the generic form for defining the magnitude response of a filter! Why … The poles and zeros are symmetric about the jw axis of the s-plane! Therefore, the LHP and RHP elements can be separated into T(s) and T(s) and guarantee marginal stability!!
Page 2
The Butterworth Lowpass Filter
nnn
ww
jwTjwT2
01
1
nn
nn
nnn
ws
wsjwj
ssTsT
2
0
2
0
22
011
1
1
1
1
1
Characteristic Eq. 0112
0
ssws
nn
Frequency normalized 011 2 nn sss
Reference: M.E. Van Valkenburg, Analog Filter Design, Oxford Univ. Press, 1982 ISBN: 0-19-510734-9
Page 3
Solving for the Butterworth Filter poles:
Filter in jw nnn
ww
jwTjwT2
01
1
Laplace
nn
nn
nnn
ws
wsjwj
ssTsT
2
0
2
0
22
011
1
1
1
1
1
Characteristic Eq. 0112
0
ssws
nn
Normalize 011 2 nn sss
For n odd:
0111 2 nnn sssss
Roots at mjs n 2exp12
n
jms
exp
Let s be the LHP poles and s be the RHP poles
For n even:
0111 2 nnn jsjssss
Roots at jmjs n 2exp12
n
jmjs
2
2exp
Let s be the LHP poles and s be the RHP poles
Page 4
Matlab Code (BW_Filter_Example.m) % BW Filter generation demonstration % close all clear all Rin=1; Rload=1; Rmatch=1; PBfreq=1; PiW=logspace(log10(PBfreq)-2,log10(PBfreq)+2,1024); colorseq=['b' 'g' 'r' 'y' 'm' 'c']; ii=0; PolesRange=6:-1:1 for BWn=PolesRange ii=mod(ii,6)+1; denP=roots([((-1/(PBfreq^2))^(BWn)) zeros(1,2*BWn-1) 1]) [Y,I] = sort(real(denP)); denPsort=denP(I) den=poly(denPsort(1:BWn)); figure(1) plot(real(denP),imag(denP),sprintf('%cx',colorseq(ii)) ); title('Power Magnitude Poles') grid on; hold on; num = [PBfreq^(BWn)]; zpi=abs(roots(num)); ppi=abs(roots(den)); BWsys=tf(num,den) [PiMAG, PiPHASE]=bode(BWsys,PiW); figure(2) semilogx(PiW, dBv(squeeze(PiMAG)),colorseq(ii) ); grid on; hold on; title('Power vs. Frequency') xlabel('Freq (rad/sec)'); ylabel('Magnitude dB'); plotv=axis; axis([plotv(1) plotv(2) -120 10]) figure(3) semilogx(PiW, (squeeze(PiPHASE)),colorseq(ii) ); grid on; hold on; title('Phase vs. Frequency') xlabel('Freq (rad/sec)'); ylabel('Phase'); axis([plotv(1) plotv(2) -max(PolesRange)*90 15]) pause end
Page 5
Results
-1 -0.8 -0.6 -0.4 -0.2 0 0.2 0.4 0.6 0.8 1
-1
-0.8
-0.6
-0.4
-0.2
0
0.2
0.4
0.6
0.8
1
Power Magnitude Poles
10-2
10-1
100
101
102
-120
-100
-80
-60
-40
-20
0
Power vs. Frequency
Freq (rad/sec)
Mag
nitu
de d
B
10-2
10-1
100
101
102
-500
-450
-400
-350
-300
-250
-200
-150
-100
-50
0
Phase vs. Frequency
Freq (rad/sec)
Pha
se
Page 6
What if we want to change the frequency …
nn
nnn
ws
wjs
sTsT2
0
2
011
1
1
1
Just change the natural frequency, 00 2 fw ; the center frequency is simply scaled!
The circle radius of the poles defines the cut-off frequency.
nnn
n
nnsw
wsTsT
220
20
1
Design approach:
1. Determine the order of the filter you want. What attenuation do you need at the 010 w
point? (There are plenty of curves, like those above, if the value you need comes before t 10x the cutoff frequency.)
2. Generate the Butterworth Coefficients on the unit circle for w=1
3. Scale the poles by the desired frequency (remember that w=1 is in radians/sec, therefore multiply by 00 2 fw .
Page 7
Active Audio Frequency Filters
An active lowpass filter implementation of a 1st order Butterworth filter
+
-R1
R2
VinOP-Amp
Vout
C2
The transfer function for this circuit is
221
2
1 CsRR
R
sVin
sVout
1
2
R
RGMaxGain
220
1
RCw
To tune the circuit ….
Page 8
An alternate approach:
+
-
R1
Ra
+Vdc
-Vdc
V1OP-Amp
Vout
C1
Rb
111
1
CsRR
RR
sVin
sVout
b
ba
b
ba
R
RRGMaxGain
110
1
CRw
To tune the circuit ….
Page 9
A Second Order Butterworth Lowpass Filter
Let’s do the math for the second order system, for n=2 and 10 w .
22
0
222
0
22
11
1
1
1
ws
wjs
sTsT
1212
1
1
122422
ssssssTsT
12
1
12
12222
sssTand
sssT
For sT2 12
1
12
1222
ssss
sT
A second order underdamped system with 22 or 707.02
1
21
211, 2
21 jss
After frequency scaling
221, 002
0021wjwwwss
How to make a second order LPF for audio ….
Page 10
Sallen-Key Circuit Lowpass Filter
An active lowpass filter implementation of a unity gain Friend Circuit, also referred to as a Sallen-Key circuit as described in: Walter G. Jung, IC OP-Amp Cookbook, Howard W. Sams Co. Inc, Indianapoli, IN, 1974.
The transfer function for this circuit is (a generic second order filter equation is also shown)
22
2
22
2121
1
213
4
22
1
12
1
2121
1
3
43
1 wsws
wK
RRCCRCR
R
RCRCss
RRCCR
RR
sV
sVout
2121123
411211
1
3
43
1 2 RRCCsRCRRRCRCsR
RR
sV
sVout
Letting CCC 21 and RRR 21 and 3
43
R
RRK
3
43
R
RRKMaxGain
RCw
1
2
3 K
+
-
R1 R2+Vdc
-Vdc
V1OP-Amp
Vout
C2
R3
R4
C1
Page 11
Function Derivation
The circuit derivation assumes a perfect op-amp, with infinite gain, infinite input impedance, and zero output impedance, non-limiting power supplies and voltage drops, and no frequency response considerations.
The circuit derivation follows:
221
12
2
1
1
12 CsVo
R
Vp
R
VCs
RRV
2
21
2
1
R
VCs
RVp
VoRR
RVn
43
3
Letting VnVp
2
21
2
1
43
3
R
VCs
RRR
RVo
Vo
RR
RCsRV
43
21132
22112
2
1
12
2
1
1
12 CsVo
RCsR
V
R
VCs
RRV
21
12
211
1
1
12 CsVo
R
VCs
RCs
Cs
RV
1
122
211
1
1
1
43
2113
R
VCsVoCs
RCs
Cs
RRR
RCsRVo
1
12
1
21211211211
43
3 2
R
VCsVo
R
RRCCsRCsRCsRCs
RR
RVo
1
1
1
21213
41211211
43
32
R
V
R
RRCCsR
RRCsRCsRCs
RR
RVo
Page 12
1
21213
41211211
1
3
43
2
V
RRCCsR
RRCsRCsRCs
R
RRVo
2121
1
213
4
22
1
12
1
2121
1
3
43
12
RRCCRCR
R
RCRCss
RRCCR
RR
V
Vo
Letting CCC 21 and RRR 21 and 3
43
R
RRG
22
2
13
1
1
RCRC
Gss
RCG
V
Vo
Resulting in
3
43
R
RRGMaxGain
RC
w
1
And 2
3 G
Note that for a stable system 31 G
Implying that 3240 RR
Page 13
Multiple Feedback (MFB) Circuit Lowpass Filter
An active lowpass filter implementation of a multiple feedback circuit (MFB), that is may also be referred to as a derivative of the Sallen-Key Filter.
+
-R1 R2
+Vdc
-Vdc
V1OP-Amp
Vout
C2
C1
R3
Figure 1. MFB Lowpass Filter
The transfer function for this circuit is
32211
311
211
111
32211
1
3
1 2
RRCCRCRCRCssRRCC
R
R
V
Vo
3221223213221
1
1
3
1 2 RRCCsRCRCRRRCsR
R
V
Vo
Resulting in
1
3
R
RKMaxGain 3221
1RRCCw
Letting CC 2 , CnC 1 , RRR 31 , RmR 2 , and 1G
22
2
222 2211
1
1 wsws
wK
CRmnsmRCsV
Vo
1 KMaxGain mnCR
w
1
mn
m
2
21
Page 14
Function Derivation
The circuit derivation assumes a perfect op-amp, with infinite gain, infinite input impedance, and zero output impedance, non-limiting power supplies and voltage drops, and no frequency response considerations.
The circuit derivation follows:
31
11
3
1
2
1
1
12
R
Vo
R
VCs
RRRV
02
22
R
VVoCs
Combining 31
11
3
1
2
1
1
122
R
Vo
R
VCs
RRRRCsVo
1
1
3321
321132312122
R
V
R
Vo
RRR
RRRCsRRRRRRRCsVo
1
1
31
3212132312121 2
R
V
RR
RRRCCsRRRRRRCsRVo
3212132312121
3
1 2 RRRCCsRRRRRRCsR
R
V
Vo
32211
311
211
111
32211
1
3
1 2
RRCCRCRCRCssRRCC
R
R
V
Vo
Resulting in
1
3
R
RGMaxGain 3221
1RRCCw
And 311
211
111
2
1RCRCRCw
Page 15
Higher Order Butterworth Lowpass Filters
Take multiple stages and cascade them!
Remember to determine the pole locations that each stage of the filter requires.
As a rule-of-thumb, you should select the order for the stages of your filter. If you look at the output of each stage, it will be the product of the transfer functions to that location! So, possible use those with damping factors closest to one before the smaller ones ….
Jim Karki, Texas Instruments, Active Low-Pass Filter Design, Application Report, SLOA049B, September 2002.
Note:
1. Real elements may not exactly match the values you select.
2. Components have a tolerance, they are within +/- some %!
3. If possible use cheaper components and one (or two) that are adjustable (potentiometers).
What do RF designers do?
Why might it be different?
Page 16
Low Pass Filter, 3rd Order
The classic 3rd order LC Ladder Low Pass Filter.
C2
Vin Vout
L1 L3
Figure 2. LC Ladder 3rd Order Low Pass Filter
The circuit derivation assumes a source and load resistance. The source resistance is placed prior to the input voltage and the load is placed on the output.
For RRLRs and LLL 21 :
2211
21
2 LCs
RCs
R
Ls
Vin
Vout
Page 17
Theoretical Derivation
The circuit derivation assumes a source and load resistance. The source resistance is placed prior to the input voltage and the load is placed on the output.
The circuit node equations follow:
3
12
3
11
LsV
LsRLVout
1
1
3
1
3
12
1
12
LsRsVin
LsVout
LsCs
LsRsV
Solving for V2 and substituting:
RL
LsRLVoutV
32
1
1
3
1
3
12
1
13
LsRsVin
LsVout
LsCs
LsRsRL
LsRLVout
1
1
3
1
31
132313 2
LsRsVin
LsVout
LsLsRs
LsRsLCsLsLsRs
RL
LsRLVout
Vin
RLLs
RLLsRsLsRsLCsLsLsRsLsRLVout
3
1132313 2
RLLsRsLsRsLCsLsLsRsLsRL
RLLs
Vin
Vout
1132313
32
1323131323
322 LsRsLCsLsLsRsLsLsRsLCsLsRL
RLLs
Vin
Vout
13231122 22 LsRsLCsLsLsRsRLLCsRsRLCsRL
RL
Vin
Vout
1323212231 32 LLCsRsLCRLLCsRsRLCLLsRsRL
RL
Vin
Vout
RsRL
LLCs
RsRL
RsLCRLLCs
RsRL
RsRLC
RsRL
LLs
RsRL
RL
Vin
Vout
13232122
311
1
32
Page 18
For RRLRs :
1323122312 322 LLCsRLLCsRCLLsR
R
Vin
Vout
or
R
L
R
LRCs
R
L
R
LRCsRC
R
L
R
Ls
Vin
Vout
312
3122
312
1
32
For LLL 21 :
2322 LCsRsRLLCsRsRLCLsRsRL
RL
Vin
Vout
RsRL
LCsLCs
RsRL
RsRLC
RsRL
Ls
RsRLRL
Vin
Vout
2
3221
For RRLRs and LLL 21 :
2211
21
221
21
22
32 LCs
RCs
R
Ls
R
LCsLCs
RC
R
Ls
Vin
Vout
Page 19
Theoretical Derivation Pi-Filter
Vin Vout
L2
C1 C2
Figure 3. LC Ladder 3rd Order Low Pass Filter
The circuit derivation assumes a source and load resistance. The source resistance is placed prior to the input voltage and the load is placed on the output.
For RRLRs and CCC 31 :
2211
1
2
1
2 CLs
R
LsRCs
Vin
Vout
Page 20
Theoretical Derivation Pi-Filter
The circuit derivation assumes a source and load resistance. The source resistance is placed prior to the input voltage and the load is placed on the output.
The circuit node equations follow:
2
123
2
11
LsVCs
LsRLVout
RsVin
LsVout
LsCs
RsV
1
2
1
2
11
12
Solving for V2 and substituting:
RL
RLCLsLsRLVoutV
3222
2
RsVin
LsVout
LsCs
RsRL
RLCLsLsRLVout
1
2
1
2
11
1322 2
RsVin
LsVout
RsLs
RsLCsLsRs
RL
RLCLsLsRLVout
1
2
1
2
212322 22
Rs
VinRLRsLs
RsRLRsRLCCLsRsCLRLCLs
LRLRsCLRsRLCLsRLLRsLsRsRL
Vout1
2
3121232
212322224223
22
Rs
VinRLRs
RsRLCCLsRsCLRLCLs
LRLRsCRsRLCsRLRs
Vout13121232
21332
RsRLCCLsRsCLRLCLs
LRLRsCRsRLCsRLRs
RL
Vin
Vout
3121232
21332
Page 21
RLRs
RLRsCCLs
RLRs
RsCLRLCLs
RLRs
Ls
RLRs
RLRsCCsRLRs
RL
Vin
Vout
312
12322131
1
3
2
For RRLRs :
2
3121322
2131
1
2
1
32 RCCLsCCLs
R
LCRCRs
Vin
Vout
For CCC 31 :
RLRs
RLRsCCLsCLs
RLRs
LRLRsCsRLRs
RL
Vin
Vout
2222
1
1
32
For RRLRs and CCC 31 :
221
1
2
1
232 RCLsCLs
R
LRCs
Vin
Vout
2211
1
2
1
2 CLs
R
LsRCs
Vin
Vout
Page 22
1.5 MHz Low Pass Filter, 7th Order, Coilcraft P7LP155
The 7th order elliptical LC Ladder Low Pass Filter.
Figure 4. Coilcraft LC Ladder Low Pass Filter
Manufacturer’s frequency response
Coilcraft LC Ladder Low Pass Filter
Page 23
Test Analysis
A test circuit was built and tested using the network analyzer.
R is assumed to be 50 ohms, L1 and L3 were variable inductors in the range of 0.578 to 0.95 uH and C2 was 4 parallel 100pF (101K) capacitors or 400 pF.
Network Analyzer Measurements
Page 24
References
[1] Walter G. Jung, IC OP-Amp Cookbook, Howard W. Sams Co. Inc, Indianapoli, IN, 1974.
[2] M.E. Van Valkenburg, Analog Filter Design, Oxford, 1982. ISBN: 0-19-510734-9.
[3] http://www.circuitsage.com/filter.html
[4] http://focus.ti.com/analog/docs/techdocs.tsp?contentType=8&familyId=78&navSection=app_notes
TI Application Notes: Slod006b Sloa093
TI Application Notes on Filtering Active Filter Design Techniques SLOA088 Analysis of the Sallen-Key Architecture (Rev. B) SLOA024 FilterPro MFB and Sallen-Key Low-Pass Filter Design Program SBFA001A Active Low-Pass Filter Design (Rev. A) SLOA049 Using the Texas Instruments Filter Design Database SLOA062 Filter Design in Thirty Seconds SLOA093 Filter Design on a Budget SLOA065 More Filter Design on a Budget SLOA096