Example MZI (layout + circuit)

This example shows how to create a simple MZI and run a circuit simulation.

from technologies import silicon_photonics
from picazzo3.filters.mzi import MZIWaveguides
from picazzo3.wg.splitters import WgY90Splitter, WgY180Combiner
from ipkiss3 import all as i3

split = WgY90Splitter(name="my_splitter_5")
split_layout = split.Layout()

comb = WgY180Combiner(name="my_combiner_5")
comb_layout = comb.Layout()

mzi = MZIWaveguides(name="my_mzi_waveguides_1",
                    splitter=split,
                    combiner=comb,
                    splitter_port_names=['arm1', 'arm2'],
                    combiner_port_names=['arm1', 'arm2'])
layout = mzi.Layout(delay_length=100.0)

layout.visualize(annotate=True)
../_images/sphx_glr_plot_mzi_001.png

Running circuit simulation

Next, we can instantiate the circuit model to run circuit simulations. We use the circuit models that are already defined in IPKISS. If you want to build your own circuit models, please check out the tutorial on implementing circuit models in IPKISS.

import numpy as np
from pylab import plt

cm = mzi.CircuitModel()

wavelengths = np.linspace(1.5, 1.6, 1001)

S = cm.get_smatrix(wavelengths=wavelengths)

plt.figure()
plt.plot(wavelengths, np.abs(S['splitter_center', 'combiner_center'])**2, label='Transmission')
plt.xlabel("Wavelengths ($\mu$ m)")
plt.ylabel("Power transmission")
plt.show()
../_images/sphx_glr_plot_mzi_002.png