Boost Graph Library, Erdos Renyi Generator. Graphs always have same number of edges
问题 I'm trying to generate Erdos-Renyi graphs using boost graph library. In the code below, which is taken from The Boost 1.72 documentation the networks always have the same number of edges (they should not, for particular p values). I have tried using different random seeds to no avail. Thanks for any help. #include <boost/graph/adjacency_list.hpp> #include <boost/graph/erdos_renyi_generator.hpp> #include <boost/random/linear_congruential.hpp> #include <iostream> using namespace std; typedef