Line
rfnetwork.elements.Line
- class rfnetwork.elements.Line(z0=50, er=1, loss=0, frequency=0, length=None, shunt=False, state={})
Bases:
ComponentBase class for generic transmission lines.
Parameters
- z0float | list, default: 50
Characteristic impedance of line.
- erfloat | list, default: 1
Dielectric constant of substrate.
- lossfloat | list, default: 0
Total loss, (dielectric + conductor) losses, in dB per inch.
- frequencylist, optional
Array of frequencies in Hz for z0, er, and loss if they are provided as lists.
- lengthfloat, optional
Length of line segment in inches.
- shuntbool, default: False
If True, port 2 is connected to ground and port 1 is transformed into a 2-port component that can be cascaded with other components.
Examples
>>> import rfnetwork as rfn >>> ln = rfn.elements.Line( ... z0=55, ... er=[3.2, 3.5], ... loss=[0.5, 0.7], ... frequency=[10e9, 12e9], ... length=1.5, ... ) >>> ln.state {'length': 1.5, 'z0': 55, 'er': [3.2, 3.5], 'loss': [0.5, 0.7]}
If setting the length with the electrical length, keep in mind that it is relative to a wavelength in the medium, not in free space.
>>> ln1 = ln(360, f0=10e9) >>> ln1.state["length"] 0.6597...
Whereas a wavelength in free space is,
>>> rfn.const.c0_in / 10e9 1.1802...
Methods
Line.evaluate_sdata(frequency)Computes the lossy s-matrix of a transmission line.
Line.get_delay(frequency)Returns the phase delay [deg] and time delay [ps] at the specified frequency.
Line.get_properties(frequency)Returns characteristic impedance and dielectric constant over frequency.
Line.get_wavelength(frequency[, units])Returns the propagation wavelength [inches] of the medium at the specified frequency [Hz].
Attributes