Ansys Lumerical Way - EigenMode Expansion (EME)¶

When you setup an electromagnetic simulation using Ansys Lumerical MODE (using the EME solver) from inside IPKISS, you become through the post-obit steps:

  1. Define the geometry that represents your component.
  2. Specify the simulation chore, consisting of the geometry, the expected outputs and simulation settings
  3. Inspect the exported geometry
  4. Retrieve the simulation results

2. Ascertain the simulation¶

To create a simulation using the geometry we've simply defined, we'll instantiate a i3.device_sim.LumericalEMESimulation object:

                                    simulation                  =                  i3                  .                  device_sim                  .                  LumericalEMESimulation                  (                  geometry                  =                  sim_geom                  ,                  outputs                  =                  [                  i3                  .                  device_sim                  .                  SMatrixOutput                  (                  name                  =                  'smatrix'                  ,                  wavelength_range                  =                  (                  one.5                  ,                  ane.6                  ,                  fifty                  )                  )                  ],                  setup_macros                  =                  [                  i3                  .                  device_sim                  .                  lumerical_macros                  .                  eme_setup                  (                  group_spans                  =                  [                  transition_length                  ,                  mmi_length                  ,                  transition_length                  ],                  cells                  =                  [                  50                  ,                  one                  ,                  l                  ]                  ),                  i3                  .                  device_sim                  .                  lumerical_macros                  .                  eme_profile_xy                  (                  'out1'                  )                  ]                  )                

Apart from the simulation geometry we have to specify an output. By using SMatrixOutput , the simulator will perform an S-parameter sweep and return an SMatrix ( i3.circuit_sim.Smatrix1DSweep ).

We have also added ii macros:

  • eme_setup allows to command the discretization of the component in Lumerical EME. In this case the component is split into three parts: the input taper, the MMI and the output taper. The input and output tapers are discretised in the ten-management (the direction of propagation) into 50 cells, while the MMI only consists of one cell considering it has a constant width.
  • eme_profile_xy lets us place a monitor on a port and visualize the results (like the electric field) after the simulation is done.

Now everything is prepare up to start Ansys Lumerical EME and practise our first simulation.

three. Audit the simulation chore¶

To see what it looks like, you can use the inspect method:

The Lumerical EME Solver graphical user interface will open twice. First, the GUI will be opened to build up the geometry and settings in an automated manner. Then, the GUI volition close and re-open for inspection. This is for technical implementation reasons.

Afterwards execution, the Lumerical EME GUI volition open:

../../_images/eme_inspect.png

You can now explore the geometry, ports, outputs and other settings as exported by IPKISS. Y'all can make changes and alter settings from here. See Export additional settings below on how to make those settings available for time to come projects.

Note

The EME solver will be set up with x cells in the propagation direction to let a fast initial setup. In well-nigh cases the number of cells and prison cell groups needs to be setup by the user using the macro i3.device_sim.lumerical_macros.eme_setup() to go far at a meaningful simulation. This can be done after initial inspection of the project.

four. Call back and plot simulation results¶

When you lot've confirmed that the simulation setup is correct, you can continue with running the simulation and retrieving the results from the outputs. Past default yous don't have to launch the simulation explicitly; when you asking the results, IPKISS volition run the simulation when required.

                                    import                  numpy                  as                  np                  smatrix                  =                  simulation                  .                  get_result                  (                  proper name                  =                  'smatrix'                  )                  transmission                  =                  np                  .                  abs                  (                  smatrix                  [                  'out1'                  ,                  'in'                  ])                  **                  2                

Note

By default, the S-matrix that is returned later on the simulation volition have its sweep units in micrometer. This is in contrast to manually importing the South-matrix touchstone file using import_touchstone_smatrix , in which case the default sweep units are in GHz.

Since not all tools use the same physics conventions (due east.grand. \(\exp(-j\omega t)\) vs \(\exp(j \omega t)\)), IPKISS will ensure that the S-parameters are converted from the tool conventions into IPKISS conventions (\(\exp(-j\omega t)\)).

You can now plot these S-parameters with matplotlib, or they can be stored to deejay (S-parameter data handling). Lumerical EME will also create a touchstone file named 'smatrix.s3p' that tin can be imported using import_touchstone_smatrix .

                                    import                  numpy                  every bit                  np                  import                  matplotlib.pyplot                  as                  plt                  wavelengths                  =                  smatrix                  .                  sweep_parameter_values                  dB                  =                  lambda                  10                  :                  20                  *                  np                  .                  log10                  (                  np                  .                  abs                  (                  10                  ))                  plt                  .                  effigy                  ()                  plt                  .                  plot                  (                  wavelengths                  ,                  dB                  (                  smatrix                  [                  "out1"                  ,                  "in"                  ]),                  label                  =                  'transmission'                  ,                  linewidth                  =                  3                  ,                  color                  =                  'g'                  ,                  mark                  =                  'o'                  )                  plt                  .                  plot                  (                  wavelengths                  ,                  dB                  (                  smatrix                  [                  "out2"                  ,                  "out1"                  ]),                  label                  =                  'crosstalk'                  ,                  linewidth                  =                  three                  ,                  colour                  =                  'b'                  ,                  marker                  =                  'o'                  )                  plt                  .                  fable                  ()                  plt                  .                  xlabel                  (                  'wavelength [$\mu m$]'                  )                  plt                  .                  ylabel                  (                  'S-parameter magnitude [dB]'                  )                  plt                  .                  show                  ()                

../../_images/eme_sweep.png

Just the manual to the 'out1' port is plotted because the MMI is symmetric. We come across that less than half of the power is transmitted to each output port, and then the MMI tin be optimized farther.

The electric field at the output port tin be visualized thank you to the monitor we placed before:

../../_images/eme_electric_field.png

five. Advanced simulation settings¶

Monitors¶

Merely equally is the example with the geometry, IPKISS sets reasonable defaults for the port monitors . When you don't specify any ports, defaults will automatically be added. The default position, direction are directly taken from the OpticalPorts of the layout, the dimensions of the Ports are calculated with a heuristic. Specifically, the width of the port is taken from the core_width attribute of the trace_template of the IPKISS OpticalPort. Any waveguide template that is a WindowWaveguideTemplate will have this attribute. For the majority of waveguide templates this is the instance. The heuristic will add a fixed margin of 1um to this core_width . The summit of the port is derived from the Material Stack used to near fabricate the layer of the core of the Waveguide, searching for the highest refractive index region just excluding the bottom, height, left and right boundary materials.

You can override these defaults by using the monitors statement of the simulator class:

                                        simulation                    =                    i3                    .                    device_sim                    .                    LumericalEMESimulation                    (                    geometry                    =                    sim_geom                    ,                    monitors                    =                    [                    i3                    .                    device_sim                    .                    Port                    (                    name                    =                    'in'                    ,                    # we make the box of the port quite big for sit-in purposes                    box_size                    =                    (                    5.                    ,                    v.                    )                    ),                    i3                    .                    device_sim                    .                    Port                    (                    name                    =                    'out1'                    ),                    i3                    .                    device_sim                    .                    Port                    (                    name                    =                    'out2'                    )                    ]                    )                  

Notation that you can not change the x-position of the monitors in Lumerical EME. When you inspect the simulation object you lot'll run into something similar to the picture beneath:

../../_images/eme_monitors.png

Multimode waveguides

By default, waveguide ports will be simulated with a single mode (the primal manner). You can override this in order to take multiple modes into account:

                                        simjob                    =                    i3                    .                    device_sim                    .                    LumericalEMESimulation                    (                    geometry                    =                    sim_geom                    ,                    monitors                    =                    [                    i3                    .                    device_sim                    .                    Port                    (                    proper name                    =                    "in"                    ,                    n_modes                    =                    2                    ),                    i3                    .                    device_sim                    .                    Port                    (                    proper name                    =                    "out1"                    ,                    n_modes                    =                    two                    ),                    i3                    .                    device_sim                    .                    Port                    (                    proper name                    =                    "out2"                    ,                    n_modes                    =                    ii                    )],                    outputs                    =                    [                    i3                    .                    device_sim                    .                    SMatrixOutput                    (                    name                    =                    'smatrix'                    ,                    wavelength_range                    =                    (                    one.five                    ,                    ane.6                    ,                    50                    )                    )                    ],                    setup_macros                    =                    [                    i3                    .                    device_sim                    .                    lumerical_macros                    .                    eme_setup                    (                    group_spans                    =                    (                    transition_length                    ,                    mmi_length                    ,                    transition_length                    ),                    cells                    =                    [                    fifty                    ,                    i                    ,                    50                    ],                    display_cells                    =                    False                    )]                    )                  

The expectation is that the tool will order the modes co-ordinate to descending propagation constant, the ground mode being the beginning mode, the mode with the 2nd largest propagation constant 2d, and and so forth.

The simulation results volition then contain the S-parameters for each port-style combination:

                                        smatrix                    =                    simjob                    .                    get_result                    (                    name                    =                    'smatrix'                    )                    import                    numpy                    as                    np                    import                    matplotlib.pyplot                    every bit                    plt                    wavelengths                    =                    smatrix                    .                    sweep_parameter_values                    dB                    =                    lambda                    10                    :                    20                    *                    np                    .                    log10                    (                    np                    .                    abs                    (                    10                    ))                    plt                    .                    figure                    ()                    plt                    .                    plot                    (                    wavelengths                    ,                    dB                    (                    smatrix                    [                    "out1:0"                    ,                    "in:0"                    ]),                    marker                    =                    'o'                    ,                    label                    =                    'manual 0'                    ,                    linewidth                    =                    3                    ,                    color                    =                    'g'                    )                    plt                    .                    plot                    (                    wavelengths                    ,                    dB                    (                    smatrix                    [                    "out1:1"                    ,                    "in:1"                    ]),                    marker                    =                    'o'                    ,                    characterization                    =                    'transmission i'                    ,                    linewidth                    =                    three                    ,                    color                    =                    'b'                    )                    plt                    .                    legend                    ()                    plt                    .                    xlabel                    (                    'wavelength [$\mu m$]'                    )                    plt                    .                    ylabel                    (                    'South-parameter magnitude [dB]'                    )                    plt                    .                    prove                    ()                  

../../_images/eme_multimode.png