Hi all
I found remove_vertex member for vector_as_graph isn't implemented.
It's my proposal:
template<class EdgeList, class Allocator>
void
remove_vertex(typename EdgeList::value_type u,
std::vector<EdgeList, Allocator>& g)
{
typedef typename EdgeList::iterator iterator;
clear_vertex(u, g);
g.erase(g.begin() + u);
for (std::size_t i = 0; i < g.size(); ++i)
for ( iterator it = g[i].begin(); it != g[i].end(); ++it )
// after clear_vertex none *it is equal to u
if ( *it > u )
--*it;
}
Regards,
Janusz
_______________________________________________
Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost