rustworkx icon indicating copy to clipboard operation
rustworkx copied to clipboard

Add network's `non_edges`

Open ElePT opened this issue 2 months ago • 1 comments

What is the expected enhancement?

It would be handy to have this method implemented in rustworkx: https://networkx.org/documentation/stable/reference/generated/networkx.classes.function.non_edges.html we could use it in https://github.com/Qiskit/qiskit-addon-opt-mapper/blob/main/qiskit_addon_opt_mapper/applications/tsp.py#L71-L84.

ElePT avatar Oct 22 '25 13:10 ElePT

This should be trivial to implement with https://www.rustworkx.org/apiref/rustworkx.graph_complement.html

We can also leverage an optimized version

IvanIsCoding avatar Oct 23 '25 16:10 IvanIsCoding