S6 · Lesson 25 · Filter lab
Ladder responses from ABCD matrices, the bandpass transformation and Richards' stub filters, in Python
Lessons 21 to 24 synthesized filters from prototype tables and transformations, each step justified by algebra. This lab checks the whole chain by simulation: it builds the ladder from its element values, multiplies the elements' ABCD matrices and reads the insertion loss, then does the same for the bandpass filter's actual inductors and capacitors and for the Richards stub filter, whose response must equal the prototype's at Richards' frequency variable and repeat every four cutoff frequencies.
- The curves are a third-order Butterworth stub filter's insertion loss against frequency, with , and its lumped prototype's, .
- Below cutoff the two nearly agree; the stub filter's loss climbs faster and becomes infinite at , where the stubs are a quarter wave.
- Beyond it falls again and passes near : the spurious passband of every distributed filter.
Predict
A 0.5 dB, N = 3 Chebyshev bandpass filter at 1 GHz with 10% bandwidth in 50 Ω is built from the transformed inductors and capacitors. What loss does it give at 1.1 GHz?
The mapping sends 1.1 GHz to 1.909, where the prototype loses 17.8 dB. Each transformed resonator presents exactly the prototype element's reactance at the mapped frequency, so the lab's ladder of real LC values gives 17.826 dB, matching the prototype to every digit.
Name it
Simulating a ladder
With 1 Ω terminations and a ladder that starts with a shunt capacitor , alternating with series inductors:
- a shunt element of admittance Y is [[1, 0], [Y, 1]]; a series element of impedance Z is [[1, Z], [0, 1]];
- the product of all of them, A B C D, gives for equal terminations , and the insertion loss is .
Bandpass elements
At center and fractional bandwidth Δ in : a shunt prototype capacitor g becomes a parallel LC with , ; a series inductor g becomes a series LC with , .
Stub filters
Richards' filter replaces each shunt capacitor g with an open stub of admittance g (in units of ) and each series inductor with a short-circuited stub of impedance g, both λ/8 long at . A shunt open stub adds ; a series short stub adds , with .
Check
Write butter_g(N) and ladder_db(g, w): the insertion loss at normalized frequency w of a ladder with 1 Ω terminations and elements g (shunt C first, alternating), from ABCD matrices.
Python 3.14 with numpy and matplotlib, running in your browser. Tab indents; press Esc and then Tab to move on.
Check
Write bandpass_db(g, f, f0, fbw, R0): the insertion loss of the bandpass filter built from prototype g (shunt first) by the transformation, at frequency f, from its actual L and C values.
Python 3.14 with numpy and matplotlib, running in your browser. Tab indents; press Esc and then Tab to move on.
Check
Write richards_db(g, r): the loss of a Richards stub filter (shunt open stubs of admittance g, series short stubs of impedance g, all λ/8 at cutoff) at r times the cutoff frequency.
Python 3.14 with numpy and matplotlib, running in your browser. Tab indents; press Esc and then Tab to move on.
Explain why
Why is a bandpass filter's passband geometrically, not arithmetically, centered on its center frequency?
The lowpass-to-bandpass transformation replaces each reactance with a resonator whose reactance depends on . That quantity takes equal and opposite values at two frequencies whose product is , so the filter's response is the same at those two frequencies: symmetric about on a logarithmic frequency axis. For a 10% filter at 1 GHz the 0.5 dB edges come out at 0.951 and 1.051 GHz, not 0.95 and 1.05; for narrow filters the difference is small, but for wide ones the upper side of the band is noticeably wider than the lower.