Optical waveguides and waveguide templates

In IPKISS, optical waveguides are based on two concepts: the waveguide template, and the waveguide itself. The waveguide template defines all the aspects of the waveguide that can be extracted from its cross section:

  • how the waveguide is drawn along the shape of the waveguide, i.e. the geometrical cross section;

  • the simulation model, e.g. the effective index of the waveguide.

The waveguide is then drawn based on the following properties:

  • the path of the waveguide (through the shape property);

  • how the bending is performed.

For a detailed guide, please check the waveguide guide. For a tutorial, please check out the waveguide tutorial on Luceda Academy.

WindowWaveguideTemplate

Most waveguides can be built using windows. A window is a cross-section in a gdsii layer. By defining several windows the cross section of the waveguide can be defined.

class ipkiss3.all.WindowWaveguideTemplate

Template PCell for an Optical Waveguide Trace based on TraceWindows.

Parameters
name: String that contains only ISO/IEC 8859-1 (extended ASCII py3) or pure ASCII (py2) characters

The unique name of the pcell

Views

class Layout
Parameters
windows: List with type restriction, allowed types: <class ‘ipkiss3.pcell.trace.window.window._TraceWindow’>

List of Trace Windows that know how to draw themselves relative to the shape of the Trace

core_layer: __Layer__

layer used to define the core of the waveguide

core_width: float and number > 0

width of the waveguide core

pin_shape: Shape

shape to be used for the pins

trace_template_for_ports: _TraceTemplate.Layout

Trace template to be used for the ports. Default = this template

width: float and Real, number and number >= 0
control_shape_layer: __Layer__

layer on which the control shape is drawn

draw_control_shape: ( bool, bool_, bool or int )

draws the control shape on top of the waveguide

cover_layers: List with type restriction, allowed types: <class ‘ipkiss.primitives.layer.Layer’>

layers that can be used to generate additional coverage of the trace (e.g. manhattan corners)

view_name: String that contains only alphanumeric characters from the ASCII set or contains _$. ASCII set is extended on PY3.

The name of the view

Examples

from technologies import silicon_photonics  # noqa: F401

from ipkiss3.pcell.photonics.waveguide import WindowWaveguideTemplate
from ipkiss3.pcell.trace.window.window import PathTraceWindow
import ipkiss3.all as i3

class MyWgTemplate(WindowWaveguideTemplate):
    class Layout(WindowWaveguideTemplate.Layout):
        core_width = i3.PositiveNumberProperty(doc="Core width of the waveguide")
        cladding_width = i3.PositiveNumberProperty(doc="Cladding width of the waveguide")

        def _default_core_width(self):
            return 0.45

        def _default_cladding_width(self):
            return 4.0

        def _default_cover_layers(self):
            # Layer for Manhattan rectangles
            # (drawn in waveguide bends when the waveguide manhattan parameter = True)
            return []

        def _default_windows(self):
            return [
                PathTraceWindow(
                    layer=i3.TECH.PPLAYER.WG.CORE,
                    start_offset=-0.5 * self.core_width,
                    end_offset=+0.5 * self.core_width,
                ),
                PathTraceWindow(
                    layer=i3.TECH.PPLAYER.WG.CLADDING,
                    start_offset=-0.5 * self.cladding_width,
                    end_offset=+0.5 * self.cladding_width,
                ),
            ]

# Instantiate the new waveguide template to use it in our waveguide below
wg_tmpl = MyWgTemplate()

wg = i3.RoundedWaveguide(trace_template=wg_tmpl)
wg_lay = wg.Layout(shape=[(0, 0), (10, 0), (10, 10)])

wg_lay.visualize(annotate=True)
../../../_images/index-11.png

TraceTemplate

Simple trace template for drawing waveguides.

class ipkiss3.all.TraceTemplate

Template for a Basic Trace on a chip.

Parameters
name: String that contains only ISO/IEC 8859-1 (extended ASCII py3) or pure ASCII (py2) characters

The unique name of the pcell

Views

class Layout
Parameters
layer: __Layer__
control_shape_layer: __Layer__

layer on which the control shape is drawn

draw_control_shape: ( bool, bool_, bool or int )

draws the control shape on top of the waveguide

width: float and Real, number and number >= 0
view_name: String that contains only alphanumeric characters from the ASCII set or contains _$. ASCII set is extended on PY3.

The name of the view

Waveguide

A Waveguide is the most basic optical route.

class ipkiss3.all.Waveguide
Parameters
trace_template: PCell and _WaveguideTemplate
external_port_names: str

Dictionary for remapping of the port names of the contents to the external ports

name: String that contains only ISO/IEC 8859-1 (extended ASCII py3) or pure ASCII (py2) characters

The unique name of the pcell

Other Parameters
contents: PCell and _Trace, locked

Views

class Layout
Parameters
core_layer: __Layer__

layer used to define the core of the waveguide

cover_layers: List with type restriction, allowed types: <class ‘ipkiss.primitives.layer.Layer’>

layers that can be used to generate additional coverage of the trace (e.g. manhattan corners)

input_port: TracePort
shape: Shape

Shape from which the Trace is calculated

trace_template_for_ports: _TraceTemplate.Layout

Trace template to be used for the ports.

output_port: TracePort
control_shape_layer: __Layer__

layer on which the control shape is drawn

draw_control_shape: ( bool, bool_, bool or int )

draws the control shape on top of the waveguide

contents_transformation: GenericNoDistortTransform
flatten_contents: ( bool, bool_, bool or int )

if True, it will insert the contents as elements in the layout, rather than as an Instance

view_name: String that contains only alphanumeric characters from the ASCII set or contains _$. ASCII set is extended on PY3.

The name of the view

Other Parameters
center_line_shape: locked

Automatically calculated shape of the center line of the trace

RoundedWaveguide

A RoundedWaveguide rounds the waveguide according to a preset rounding_algorithm.

class ipkiss3.all.RoundedWaveguide
Parameters
trace_template: PCell and _WaveguideTemplate
external_port_names: str

Dictionary for remapping of the port names of the contents to the external ports

name: String that contains only ISO/IEC 8859-1 (extended ASCII py3) or pure ASCII (py2) characters

The unique name of the pcell

Other Parameters
contents: PCell and _Trace, locked

Views

class Layout
Parameters
cover_layers: List with type restriction, allowed types: <class ‘ipkiss.primitives.layer.Layer’>

layers that can be used to generate additional coverage of the trace (e.g. manhattan corners)

output_port: TracePort
shape: Shape

Shape from which the Trace is calculated

trace_template_for_ports: _TraceTemplate.Layout

Trace template to be used for the ports.

core_layer: __Layer__

layer used to define the core of the waveguide

input_port: TracePort
bend_radii: list<number > 0>

Bend radius for every individual bend.

remove_straight_angles: ( bool, bool_, bool or int )

Removes the waypoints with straight angles. Set to False if the algorithm uses waypoint-specific information.

reverse_bends: ( bool, bool_, bool or int )

When set to True, it will generate the bends backwards. This has only effect when the bend algorithm is not symmetric.

reverse_individual_bends: list<( bool, bool_, bool or int )>

When set to True, it will generate the individual bends backwards. This has only effect when the bend algorithm is not symmetric. Should have length equal to the shape for closed shapes, but equal to shape-2 for open shapes.

rounding_algorithms:

Rounding algorithm for every individual bend. Can be circular, spline, … Should have length equal to the shape for closed shapes, but equal to shape-2 for open shapes.

view_name: String that contains only alphanumeric characters from the ASCII set or contains _$. ASCII set is extended on PY3.

The name of the view

control_shape_layer: __Layer__

layer on which the control shape is drawn

draw_control_shape: ( bool, bool_, bool or int )

draws the control shape on top of the waveguide

contents_transformation: GenericNoDistortTransform
flatten_contents: ( bool, bool_, bool or int )

if True, it will insert the contents as elements in the layout, rather than as an Instance

manhattan: ( bool, bool_, bool or int )

Adds rectangular blocks in the bends to avoid as much as possible non-manhattan angles.

angle_step: float and number > 0

Angle step for rounding.

bend_radius: float and number > 0

Bend radius for the auto-generated bends.

rounding_algorithm:

Rounding algorithm used to generate the bends. Can be circular, spline, ….

Other Parameters
center_line_shape: locked

Automatically calculated shape of the center line of the trace

TaperedWaveguide

A TaperedWaveguide automatically tapers between two waveguide templates: one which is defined for the straight sections (straight_trace_template), and one which is defined for the start, end and bend sections (trace_template).

class ipkiss3.all.TaperedWaveguide

A Rounded Waveguide that tapers to another template (straight_trace_template) in straight sections

Parameters
straight_trace_template: PCell and _TraceTemplate, required

template for the straight sections.

trace_template: PCell and _TraceTemplate

template for the start, end and bend sections.

external_port_names: str

Dictionary for remapping of the port names of the contents to the external ports

name: String that contains only ISO/IEC 8859-1 (extended ASCII py3) or pure ASCII (py2) characters

The unique name of the pcell

Other Parameters
contents: PCell and _Trace, locked

Examples

"""A TaperedWaveguide automatically transitions (=tapers) between different waveguide types."""
from technologies import silicon_photonics  # noqa: F401
import ipkiss3.all as i3
from picazzo3.traces.rib_wg import RibWaveguideTemplate

rib_tmpl = RibWaveguideTemplate()
rib_tmpl.Layout(core_width=0.6)
rib_tmpl_wide = RibWaveguideTemplate()
rib_tmpl_wide.Layout(core_width=1.6)

twg = i3.TaperedWaveguide(trace_template=rib_tmpl, straight_trace_template=rib_tmpl_wide)
lay = twg.Layout(shape=[(0, 0), (30, 0), (30, 60)])
lay.visualize(annotate=True)
../../../_images/index-21.png
"""TaperedWaveguide exposes the same properties as RoundedWaveguide."""

from technologies import silicon_photonics  # noqa: F401
import ipkiss3.all as i3
from picazzo3.traces.rib_wg import RibWaveguideTemplate

rib_tmpl = RibWaveguideTemplate()
rib_tmpl.Layout(core_width=0.6)
rib_tmpl_wide = RibWaveguideTemplate()
rib_tmpl_wide.Layout(core_width=1.6)

twg = i3.TaperedWaveguide(trace_template=rib_tmpl, straight_trace_template=rib_tmpl_wide)
lay = twg.Layout(
    shape=[(0, 0), (50, 0), (75, 50)],
    bend_radius=30,
    # we choose a large angle_step to show how it impacts the discretisation
    angle_step=20,
)
lay.visualize(annotate=True)
../../../_images/index-31.png

Views

class Layout
Parameters
contents_transformation: GenericNoDistortTransform
draw_control_shape: ( bool, bool_, bool or int )

draws the control shape on top of the waveguide

flatten_contents: ( bool, bool_, bool or int )

if True, it will insert the contents as elements in the layout, rather than as an Instance

flatten_waveguides: ( bool, bool_, bool or int )

If true, all waveguides will be flattened one level to reduce hierarchy

min_straight: float and Real, number and number >= 0

The minimum length of any straight sections in the route

remove_straight_angles: ( ( bool, bool_, bool or int ) ), *None allowed*

Remove waypoints with straight angles. When set to None, it will only remove straight angles when all the expansion parameters are calculated automatically

straight_section_lengths: list<number >= 0>

A list of lengths for the straight_template sections of each path segment.Length of list must be identical to number of segments

straight_section_positions: list<fraction>

A list of relative positions for the straight_template sections of each path segment. Length of list must be identical to number of segments.Each position is a number between 0 (closest to first waypoint) and 1 (closest to last waypoint).0.5 will place the expanded section in the middle of the segment.

taper_length: ( float and number > 0 ), *None allowed*

length of the taper between the regular waveguide and the expanded waveguide. Ignored if taper_lengths is set. If None, the default taper lengths for each transition are chosen for each transition.

taper_lengths: list<number >= 0>

Lengths of the tapers for each section. Length of list must be identical to number of segments.

min_straight_section_length: float and Real, number and number >= 0

minimum_length of the straight sections.

view_name: String that contains only alphanumeric characters from the ASCII set or contains _$. ASCII set is extended on PY3.

The name of the view

cover_layers: List with type restriction, allowed types: <class ‘ipkiss.primitives.layer.Layer’>

layers that can be used to generate additional coverage of the trace (e.g. manhattan corners)

output_port: TracePort
shape: Shape

Shape from which the Trace is calculated

trace_template_for_ports: _TraceTemplate.Layout

Trace template to be used for the ports.

core_layer: __Layer__

layer used to define the core of the waveguide

input_port: TracePort
bend_radii: list<number > 0>

Bend radius for every individual bend.

reverse_bends: ( bool, bool_, bool or int )

When set to True, it will generate the bends backwards. This has only effect when the bend algorithm is not symmetric.

reverse_individual_bends: list<( bool, bool_, bool or int )>

When set to True, it will generate the individual bends backwards. This has only effect when the bend algorithm is not symmetric. Should have length equal to the shape for closed shapes, but equal to shape-2 for open shapes.

rounding_algorithms:

Rounding algorithm for every individual bend. Can be circular, spline, … Should have length equal to the shape for closed shapes, but equal to shape-2 for open shapes.

control_shape_layer: __Layer__

layer on which the control shape is drawn

end_straight: float and Real, number and number >= 0

The length of the straight end section of the route

rounding_algorithm: *None allowed*

rounding algorithm used to generate the bends. Can be circular, spline, …

start_straight: float and Real, number and number >= 0

The length of the straight start section of the route

manhattan: ( bool, bool_, bool or int )

Adds rectangular blocks in the bends to avoid as much as possible non-manhattan angles.

angle_step: float and number > 0

Angle step for rounding.

bend_radius: float and number > 0

Bend radius for the auto-generated bends.

Other Parameters
min_length_for_taper: float and Real, number and number >= 0, locked

minimum length needed to use tapering

center_line_shape: locked

Automatically calculated shape of the center line of the trace

TaperedWaveguideTemplate

Trace template used to create TaperedWaveguides.

class ipkiss3.all.TaperedWaveguideTemplate
Parameters
straight_trace_template: PCell and _TraceTemplate, required

template for the straight sections.

trace_template: PCell and _TraceTemplate, required

template for the start, end and bend sections.

name: String that contains only ISO/IEC 8859-1 (extended ASCII py3) or pure ASCII (py2) characters

The unique name of the pcell

Views

class Layout
Parameters
flatten_waveguides: ( bool, bool_, bool or int )

If true, all waveguides will be flattened one level to reduce hierarchy

manhattan: ( bool, bool_, bool or int )

Adds rectangular blocks in the bends to avoid as much as possible non-manhattan angles.

min_straight_section_length: float and number > 0

minimum_length of the straight template section.

taper_length: ( float and number > 0 ), *None allowed*

length of the taper between the regular waveguide and the expanded waveguide. If None, the default taper lengths for each transition are chosen for each transition.

core_width: float and number > 0

width of the waveguide core

flatten_contents: ( bool, bool_, bool or int )

if True, it will insert the referred trace as elements in the layout, rather than as an Instance

pin_shape: Shape

shape to be used for the pins

trace_template_for_ports: _TraceTemplate.Layout

Trace template to be used for the ports. Default = this template

core_layer: __Layer__

layer used to define the core of the waveguide

remove_straight_angles: ( bool, bool_, bool or int )

removes the waypoints with straight angles. Set to False if the algorithm uses waypoint-specific information.

reverse_bends: ( bool, bool_, bool or int )

When set to True, it will generate the bends backwards. This has only effect when the bend algorithm is not symmetric.

view_name: String that contains only alphanumeric characters from the ASCII set or contains _$. ASCII set is extended on PY3.

The name of the view

width: float and Real, number and number >= 0
keep_original_trace_template: ( bool, bool_, bool or int )
control_shape_layer: __Layer__

layer on which the control shape is drawn

draw_control_shape: ( bool, bool_, bool or int )

draws the control shape on top of the waveguide

cover_layers: List with type restriction, allowed types: <class ‘ipkiss.primitives.layer.Layer’>

layers that can be used to generate additional coverage of the trace (e.g. manhattan corners)

end_straight: float and Real, number and number >= 0

The length of the straight end section of the route

min_straight: float and Real, number and number >= 0

The minimum length of any straight sections in the route

rounding_algorithm: *None allowed*

rounding algorithm used to generate the bends. Can be circular, spline, …

start_straight: float and Real, number and number >= 0

The length of the straight start section of the route

angle_step: float and number > 0

Angle step for rounding.

bend_radius: float and number > 0

Bend radius for the auto-generated bends.

Other Parameters
min_length_for_taper: float and Real, number and number >= 0, locked

minimum length needed to use tapering

Using maximum bend radius

It is possible to calculate the maximum bend radius that can be used for each turn in a given shape. This can then be used with RoundedWaveguide to obtain a waveguide which uses the maximum possible radius in each bend.

maximum_bend_radii

Calculate the maximum bend radius for each turn to be made along a control shape