Skip to content

parametric.route_s_bend

route_s_bend(
*,
port1: photonforge.Port
| tuple[photonforge.Reference, str]
| tuple[photonforge.Reference, str, int]
| None = None,
port2: photonforge.Port
| tuple[photonforge.Reference, str]
| tuple[photonforge.Reference, str, int]
| None = None,
euler_fraction: Annotated[float, maximum=1, minimum=0] | None = None,
technology: photonforge.Technology | None = None,
name: str | None = None,
model: photonforge.Model | None = None,
) -> photonforge.Component

Create an S bend connecting 2 compatible ports.

Args

  • port1: First port to be connected. The port can be specified as a Port or as a tuple including a Reference, the port name, and the repetition index (optional, only for array references).
  • port2: Second port to be connected.
  • euler_fraction: Fraction of the bends that is created using an Euler spiral (see Path.arc). If None, defaults to 0.
  • technology: Component technology. If None, the default technology is used.
  • name: Component name.
  • model: Model to be used with this component. If None a WaveguideModel is used.

Returns

Component with the route, including ports and model.

Example

>>> component = pf.parametric.route_s_bend(
... port1=pf.Port((0, 0), 180, "Strip"),
... port2=pf.Port((20, 5), 0, "Strip"),
... euler_fraction=0.5,
... )

route_s_bend