insert_arc#
- insert_arc(k: PlanarDiagram, arc: tuple, **attr) None #
Inserts an arc between two nodes at specified positions in place, adjusting their endpoint positions to accommodate the new arc.
- Args:
k (PlanarDiagram): The planar diagram where the arc is being inserted. arc (tuple): A tuple containing two endpoints (endpoint_a, endpoint_b)
where each endpoint is a tuple (node, position) specifying the node and position at which the arc should be connected.
**attr: Additional attributes to apply to the arc.
- Raises:
- NotImplementedError: If an arc is attempted to be inserted within the
same node (node_a == node_b).
- Returns:
None