Skip to main content
Ctrl+K
PyAEDT - Home PyAEDT - Home
  • Getting started
  • User guide
  • API reference
  • Examples
  • Release notes
Ctrl+K
  • GitHub
  • Support
  • Getting started
  • User guide
  • API reference
  • Examples
  • Release notes
Ctrl+K
  • GitHub
  • Support

Section Navigation

  • Application and solvers
  • Material and stackup
  • 3D modeler
  • 2D modeler
  • Primitives
  • Modeler in HFSS 3D Layout
  • Modeler and components Circuit
  • Boundary objects
    • BoundaryObject
    • FarFieldSetup
    • NearFieldSetup
    • Matrix
    • MaxwellParameters
    • MaxwellMatrix
    • BoundaryObject3dLayout
    • NetworkObject
      • add_boundary_node
      • add_face_node
      • add_internal_node
      • add_link
      • add_links_from_dictionaries
      • add_nodes_from_dictionaries
      • create
      • delete
      • jsonalize_tree
      • suppress_all
      • unsuppress_all
      • update
      • update_assignment
      • update_property
      • auto_update
      • available_properties
      • boundary_nodes
      • c_links
      • children
      • command
      • face_nodes
      • faces_ids_in_network
      • internal_nodes
      • links
      • name
      • nodes
      • objects_in_network
      • properties
      • props
      • r_links
      • type
    • Sources
    • PowerSinSource
    • PowerIQSource
    • VoltageFrequencyDependentSource
    • VoltageDCSource
    • VoltageSinSource
    • CurrentSinSource
    • NativeComponentPCB
    • NativeComponentObject
    • PCBSettingsDeviceParts
    • PCBSettingsPackageParts
    • SinusoidalDictionary
    • LinearDictionary
    • PowerLawDictionary
    • ExponentialDictionary
    • SquareWaveDictionary
    • PieceWiseLinearDictionary
  • Mesh operations
  • Setup
  • Visualization
  • Logger
  • Optimetrics
  • Variable
  • Constants
  • Configuration files
  • Setup templates
  • Cable modeling
  • Filter design
  • Generic
  • PyAnsys
  • API reference
  • Boundary objects
  • NetworkObject
  • add_link

add_link#

NetworkObject.add_link(node1, node2, value, name=None)#

Create links in the network object.

Parameters:
node1str or int

String containing one of the node names that the link is connecting or an integer containing the ID of the face. If an ID is used and the node associated with the corresponding face is not created yet, it is added automatically.

node2str or int

String containing one of the node names that the link is connecting or an integer containing the ID of the face. If an ID is used and the node associated with the corresponding face is not created yet, it is added atuomatically.

valuestr or float

String containing the value and unit of the connection. If a float is passed, an R-Link is added to the network and the "cel_per_w" unit is used.

namestr, optional

Name of the link. The default is None, in which case a name is automatically generated.

Returns:
bool

True when successful, False when failed.

Examples

>>> import ansys.aedt.core
>>> app = ansys.aedt.core.Icepak()
>>> network = ansys.aedt.core.modules.boundary.Network(app)
>>> box = app.modeler.create_box([5, 5, 5], [20, 50, 80])
>>> faces_ids = [face.id for face in box.faces]
>>> connection = {"Name": "LinkTest", "Connection": [faces_ids[1], faces_ids[0]], "Value": "1cel_per_w"}
>>> network.add_links_from_dictionaries(connection)
On this page
  • add_link()
Edit on GitHub
  • Show Source

© Copyright (c) 2025 ANSYS, Inc. All rights reserved.

Created using Sphinx 8.1.3.

Built with the Ansys Sphinx Theme 1.5.3.
Last updated on