Defined in File GraphTools.hpp
Returns a random edge. By default a random node u is chosen and then some random neighbor v. So the probability of choosing (u, v) highly depends on the degree of u. Setting uniformDistribution to true, will give you a real uniform distributed edge, but will be slower. Exp. time complexity: O(1) for uniformDistribution = false, O(n) otherwise.
Graph – G The input graph.
bool – uniformDistribution Whether the random edge should be extracted uniformly at random.
std::pair<node, node> A random edge.