Boost Users :
Subject: Re: [Boost-users] [BGL] passing a graph from one function to another
From: Andrew Sutton (andrew.n.sutton_at_[hidden])
Date: 2008-11-19 14:10:59
> Yes, I tried using add_vertex and add_edge and it works fine. But I assume
> that add_vertex and add_edge is much slower than using
> graph_t myGraph(array, edge_array + num_arcs, weights, num_nodes);
> Is this true or not? Does anyone have experience on that?
> My graph has over 10^6 edges.
It should not be. The cost of insertions is constant. You'll see a slight
speedup if you're using VertexList == vecS, but since you're not, it
Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net