RatRace#

class pyedb.libraries.rf_libraries.base_functions.RatRace(edb_cell: Edb | None = None, z0: float | str = 50, freq: float | str = 10000000000.0, layer: str = 'TOP', bottom_layer: str | None = None, net: str = 'RR', width: float | str = 0.0002, nr_segments: int = 32)#

180° rat-race (ring) hybrid coupler.

Parameters:
z0float, default 50 Ω

Characteristic impedance of the ring.

freqfloat, default 10 GHz

Centre frequency.

layerstr, default “TOP”

Layer on which the ring is drawn.

bottom_layerstr | None

Layer for the ground plane (if None, no ground is drawn).

netstr, default “RR”

Net name.

widthfloat, default 0.2 mm

Micro-strip width for the ring and port stubs.

nr_segmentsint, default 32

Number of straight segments per 90° arc.

Examples

>>> rr = RatRace(freq=5e9)
>>> edb = Edb("ratrace.aedb")
>>> rr._pedb = edb
>>> rr.create()
>>> f"{rr.circumference * 1e3:.2f} mm"
'45.00 mm'

Methods

RatRace.create()

Draw the discretised ring and four 50 Ω port stubs.