Boost logo

Boost Users :

From: Christian Sturz (linuxkaffee_at_[hidden])
Date: 2008-02-25 16:12:43


Hi,

I want to use the depth_first_search algorithm. Since I need
the DFS version where a start vertex is specified, I also
have to define a ColorMap. That's the function I want to
use:

template <class Graph, class DFSVisitor, class ColorMap>
void depth_first_search(const Graph& g, DFSVisitor vis, ColorMap color,
                 typename graph_traits<Graph>::vertex_descriptor start)

However, I'm not able to define a working ColorMap. Since the map
is irrelevant for me, the default ColorMap would be fully sufficient.
Could you give me a hint how to create it?

And another short question. I want to iterate the graph backwards via
DFS. Could I use the "reverse_graph adaptor" with:

   depth_first_search( boost::make_reverse_graph(G), visitor( vis ) ...)?

Regards,
Christian

-- 
GMX startet ShortView.de. Hier findest Du Leute mit Deinen Interessen!
Jetzt dabei sein: http://www.shortview.de/?mc=sv_ext_mf@gmx

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