Ejemplo n.º 1
0
 inline void prim_minimum_spanning_tree
   (const VertexListGraph& g,
    PredecessorMap p_map,
    const bgl_named_params<P,T,R>& params)
 {
   detail::prim_mst_impl
     (g, 
      choose_param(get_param(params, root_vertex_t()), *vertices(g).first), 
      params.predecessor_map(p_map),
      choose_const_pmap(get_param(params, edge_weight), g, edge_weight));
 }
 bool bellman_dispatch(EdgeListGraph& g, Size N, 
                       WeightMap weight, DistanceMap distance, 
                       const bgl_named_params<P, T, R>& params)
 {
   dummy_property_map dummy_pred;
   return 
     detail::bellman_dispatch2
       (g, 
        get_param(params, root_vertex_t()),
        N, weight,
        choose_param(get_param(params, vertex_predecessor), dummy_pred),
        distance,
        params);
 }
Ejemplo n.º 3
0
 void
 undirected_dfs(const Graph& g, 
                const bgl_named_params<P, T, R>& params)
 {
   typedef typename get_param_type< vertex_color_t, bgl_named_params<P, T, R> >::type C;
   detail::udfs_dispatch<C>::apply
     (g,
      choose_param(get_param(params, graph_visitor),
                   make_dfs_visitor(null_visitor())),
      choose_param(get_param(params, root_vertex_t()),
                   *vertices(g).first),
      params,
      get_param(params, edge_color),
      get_param(params, vertex_color)
      );
 }