- inline std::pair<vertex_iterator,vertex_iterator>
- vertices(const Layout&) {
- return std::make_pair(vertex_iterator(0), vertex_iterator(N));
- }
- inline unsigned num_vertices(const Layout&) { return N; }
-
-}
-
-struct VertexIndexMap;
-
-namespace boost {
- struct property_traits<VertexIndexMap> {
- // Concept Readable Property Map:
- typedef int value_type, reference, key_type;
- category
-class Boost
- }};
-
-void single_source_shortest_paths(int v1,
- const double edge_weights[/*f*/],
- ) {
- boost::dijkstra_shortest_paths
- (g, v1,
+ };
+
+ // Concept Graph:
+ inline int null_vertex() { return -1; }
+
+ // Concept IncidenceGraph:
+ inline int source(int f, const Graph&) { return f&VMASK; }
+ inline int target(int f, const Graph&) { return EDGE_END2(f&VMASK, f>>ESHIFT); }
+ inline std::pair<OutEdgeIterator,OutEdgeIterator>
+ out_edges(int v, const Graph&) {
+ return std::make_pair(OutEdgeIterator(v, VE_MIN(v)),
+ OutEdgeIterator(v, VE_MAX(v)));
+ }
+ inline unsigned out_degree(int v, const Graph&) {
+ return VE_MAX(v) - VE_MIN(v);
+ }
+
+ // Concept VertexListGraph:
+ inline std::pair<VertexIterator,VertexIterator> vertices(const Graph&) {
+ return std::make_pair(VertexIterator(0), VertexIterator(N));
+ }
+ inline unsigned num_vertices(const Graph&) { return N; }
+};
+
+static void single_source_shortest_paths(int v1,
+ const double edge_weights[/*f*/],
+ double vertex_distances[/*v*/]) {
+ Graph g;
+
+ dijkstra_shortest_paths(g, v1,