# Ideal Gyrator Circuit

A gyrator is a two port which realizes the following port equations:

```  i1 = g2 * v2
i2 = -g1 * v1
```

The currents are defined as into the two port.

Consider putting an impedance Z at port 2. Then v2/i2 = -Z. Using this to substitute gives:

```  i1 = g2 * v2 = g2 * i2 * (-Z)
= g2 * (-g1 * v1) * (-Z) = g1 * g2 * v1 * Z
```

The impedance at port 1 is therefore

```  z1 = v1/i1 = 1/(g1 * g2 * Z)
```

If a capacitor (z = 1/SC) is placed across port 2 the impedance at port 1 is that of an inductor (z = SL).

CCICAP can model a gyrator with two cross coupled VCC (voltage to current) elements.

```.title Gyrator
' define a frequency of interest
.par fo 1.kHz
' get results in Real and Imaginary form
.opt r&i
' sweep frequency from fo/10 to fo*10
.ac 20 10 { fo 10 / } { fo 10 X }
' define the impedance at port 1 as v1/i1
.calc z1 { v1 i1 / }
' plot real and imaginary parts of z1
.plot ac png z1
.plot ac png z1 >
.ckt
v v1 1 1a 1.
am i1 0 1a Gyrator Z1 - imaginary part