Feature image:
Another application of using Python to demonstrate RF concepts comes in the form of a calculator to plot L-C series reactance. This plot shows two useful concepts: resonance and the effect of parasitic capacitance or inductance. For a capacitor, the magnitude of the series reactance decreases with increasing frequency, while the opposite is true for an inductor. For a capacitor with parasitic inductance, there will come a point where the two reactances are equal in magnitude and cancel each other out. This point is the resonant frequency of the combined circuit. As the frequency is increased approaching resonance, the reactance of the capacitor decreases much more rapidly than it would without the presence of the inductance. The end effect is as if we were working with a larger capacitor than what we actually have for those frequencies near resonance. Beyond resonance, the effect of the inductance dominates the response of the combined circuit and the capacitor actually behaves like an inductor!
Programming notes:
For the purposes of the RF Technology Certification program I am working on finalizing this demo as part of the workbook that follows the lecture on complex impedances and resonance. I'm having some technical challenges because I would like the plot to be able to read off the values as you move the cursor over the plot, but this functionality hasn't been implemented in the Python-esque plotting library. (The underlying Javascript library that is used does have this capability, but the translation to Python for those functions hasn't happened yet.) Another library that can be used with this Python-Javascript mashup is "Pygal," and it does have a cursor that reads off the values as the mouse is rolled over them, but I haven't been able to effect a logarithmic scale under this environment using that library.
So the struggle continues...