create_perfecte_from_objects

Hfss.create_perfecte_from_objects(startobj, endobject, axisdir=0, sourcename=None, is_infinite_gnd=False, bound_on_plane=True)[source]

Create a Perfect E taking the closest edges of two objects.

Parameters
startobj

First object (starting object for integration line)

endobject

Second object (ending object for integration line)

axisdirint or pyaedt.application.Analysis.Analysis.AxisDir, optional

Position of the port. It should be one of the values for Application.AxisDir, which are: XNeg, YNeg, ZNeg, XPos, YPos, and ZPos. The default is Application.AxisDir.XNeg.

sourcenamestr, optional

Perfect E name. The default is None.

is_infinite_gndbool, optional

Whether the Perfect E is an infinite ground. The default is False.

bound_on_planebool, optional

Whether to create the Perfect E on the plane orthogonal to AxisDir. The default is True.

Returns
pyaedt.modules.Boundary.BoundaryObject or bool

Boundary object if successful, False otherwise.

References

>>> oModule.AssignPerfectE

Examples

Create two boxes that will be used to create a Perfect E named 'PerfectE'.

>>> box1 = hfss.modeler.primitives.create_box([0,0,0], [10,10,5],
...                                           "perfect1", "Copper")
>>> box2 = hfss.modeler.primitives.create_box([0, 0, 10], [10, 10, 5],
...                                           "perfect2", "copper")
>>> perfect_e = hfss.create_perfecte_from_objects("perfect1", "perfect2",
...                                               hfss.AxisDir.ZNeg, "PerfectE")
pyaedt info: Connection Correctly created
>>> type(perfect_e)
<class 'pyaedt.modules.Boundary.BoundaryObject'>