straight

photonforge.parametric.straight(*, port_spec, length, active_model='Waveguide', technology=None, name='', tidy3d_model_kwargs={}, waveguide_model_kwargs={})

Straight waveguide section.

Parameters:
  • port_spec (str | PortSpec) – Port specification describing waveguide cross-section.

  • length (float) – Section length.

  • active_model (Literal['Tidy3D', 'Waveguide']) – Name of the model to be used by default; must be either "Tidy3D" or "Waveguide".

  • technology (Technology) – Component technology. If None, the default technology is used.

  • name (str) – Component name.

  • tidy3d_model_kwargs (dict[str, Any]) – Dictionary of keyword arguments passed to the component’s photonforge.Tidy3DModel.

  • waveguide_model_kwargs (dict[str, Any]) – Dictionary of keyword arguments passed to the component’s photonforge.WaveguideModel.

Returns:

Component with the straight section, ports and model.

Return type:

Component

component1 = straight(port_spec="Rib", length=12)

component2 = straight(
    port_spec="Strip",
    length=10,
    tidy3d_model_kwargs={"symmetry": (0, -1, 0)},
    active_model="Tidy3D",
)
straight