Examples

MMI Splitter

Build and export a 1x2 multimode interference splitter.

An MMI splitter expands one input waveguide into a wider multimode section and brings the two output waveguides back to the core width. The default MMI is a 1×2 device, so its two output ports are available to downstream placement code.

Code

from pathlib import Path

import laylight
from laylight.render import export_layout_png, new_layout
from laylight.structure.mmi import MMI


layout, top, tech = new_layout("MMI_EXAMPLE")
device = MMI(layout=layout, tech=tech)

laylight.Placer(device).into(top)

output_dir = Path("build/examples")
output_dir.mkdir(parents=True, exist_ok=True)
layout.write(str(output_dir / "mmi.gds"))
export_layout_png(
    layout,
    output_dir / "mmi.png",
    cell=top,
    max_pixels=960,
)

The code writes mmi.gds and mmi.png to build/examples.

Rendered layout

Rendered 1x2 MMI splitter

The wide center section is the multimode region. The two tapered output paths expose the splitter's output ports.

On this page