Boost logo

Boost Users :

Subject: [Boost-users] taking the subgraph of a boost graph
From: Ryan Lewis (me_at_[hidden])
Date: 2010-12-28 22:19:04


Hi,

Lets say your handed an arbitrary boost graph and an iterator to a
subset of it's vertices. You want to induce a subgraph of this graph.
How do you do this?

I looked at the boost docs and found the Subgraph < Graph > page:

http://www.boost.org/doc/libs/1_36_0/libs/graph/doc/subgraph.html

Indeed there exists a subgraph member function:

subgraph<Graph>& create_subgraph();

However this suggests, as does the example, that you want to take an
induced subgraph of a graph whose type is Subgraph < Graph >. However
my graph is just of type Graph. What is the right way to deal with
this? I've tried asking at #boost, but no one seems to be awake there.

Thanks,

-rhl


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