circuit_port#

Hfss.circuit_port(assignment: int | Object3d | EdgePrimitive | FacePrimitive, reference: int | Object3d | EdgePrimitive | FacePrimitive, port_location: int | Gravity | None = 0, impedance: int | float | str | None = 50, name: str | None = None, renormalize: bool | None = True, renorm_impedance: str | None = '50', deembed: bool | None = False) BoundaryObject#

Create a circuit port from two objects.

The integration line is from edge 2 to edge 1.

Parameters:
assignmentint or ansys.aedt.core.modeler.cad.object_3d.Object3d or
ansys.aedt.core.modeler.cad.FacePrimitive`or :class:`ansys.aedt.core.modeler.cad.EdgePrimitive

Signal object.

referenceint or ansys.aedt.core.modeler.cad.object_3d.Object3d or
ansys.aedt.core.modeler.cad.FacePrimitive`or :class:`ansys.aedt.core.modeler.cad.EdgePrimitive

Reference object.

port_locationint or ansys.aedt.core.application.analysis.Analysis.axis_directions, optional

Position of the port when an object different from an edge is provided. It should be one of the values for Application.axis_directions, which are: XNeg, YNeg, ZNeg, XPos, YPos, and ZPos. The default is Application.axis_directions.XNeg.

namestr, optional

Name of the port. The default is "".

impedanceint, str, or float, optional

Impedance. The default is "50". You can also enter a string that looks like this: "50+1i*55".

renormalizebool, optional

Whether to renormalize the mode. The default is False. This parameter is ignored for a driven terminal.

renorm_impedancestr, optional

Impedance. The default is 50.

deembedbool, optional

Whether to deembed the port. The default is False.

Returns:
ansys.aedt.core.modules.boundary.common.BoundaryObject

Boundary object.

References

>>> oModule.AssignCircuitPort

Examples

Create two rectangles in the XY plane. Select the first edge of each rectangle created previously. Create a circuit port from the first edge of the first rectangle toward the first edge of the second rectangle.

>>> from ansys.aedt.core.generic.constants import Plane
>>> plane = Plane.XY
>>> rectangle1 = hfss.modeler.create_rectangle(plane, [10, 10, 10], [10, 10], name="rectangle1_for_port")
>>> edges1 = hfss.modeler.get_object_edges(rectangle1.id)
>>> first_edge = edges1[0]
>>> rectangle2 = hfss.modeler.create_rectangle(plane, [30, 10, 10], [10, 10], name="rectangle2_for_port")
>>> edges2 = hfss.modeler.get_object_edges(rectangle2.id)
>>> second_edge = edges2[0]
>>> hfss.solution_type = "Modal"
>>> hfss.circuit_port(
...     first_edge, second_edge, impedance=50.1, name="PortExample", renormalize=False, renorm_impedance="50"
... )
'PortExample'