pub fn complement(graph: &Graph) -> Graph
The complement G’ has the same nodes as G but has edges where G does not (and vice versa). Self-loops are not included. Matches networkx.complement(G).
networkx.complement(G)