src/work/jacint/prim.cc
changeset 220 7deda4d6a07a
parent 211 9222a9b8b323
child 258 94bafec4f56f
     1.1 --- a/src/work/jacint/prim.cc	Sat Mar 20 19:39:42 2004 +0000
     1.2 +++ b/src/work/jacint/prim.cc	Sat Mar 20 20:06:23 2004 +0000
     1.3 @@ -1,6 +1,7 @@
     1.4  #include <iostream>
     1.5  #include <fstream>
     1.6  
     1.7 +#include <smart_graph.h>
     1.8  #include <list_graph.h>
     1.9  #include <dimacs.h>
    1.10  #include <prim.h>
    1.11 @@ -12,18 +13,18 @@
    1.12  using namespace hugo;
    1.13  
    1.14  int main(int, char **) {
    1.15 -  typedef ListGraph::Node Node;
    1.16 +  typedef SmartGraph::Node Node;
    1.17  
    1.18 -  ListGraph G;
    1.19 +  SmartGraph G;
    1.20    Node s, t;
    1.21 -  ListGraph::EdgeMap<int> cap(G);
    1.22 +  SmartGraph::EdgeMap<int> cap(G);
    1.23    readDimacsMaxFlow(std::cin, G, s, t, cap);
    1.24  
    1.25    std::cout << "prim demo ..." << std::endl;
    1.26    
    1.27    double pre_time=currTime();
    1.28 -    Prim<ListGraph, int, FibHeap<ListGraph::Node, int, 
    1.29 -    ListGraph::NodeMap<int> > > prim_test(G, cap);
    1.30 +    Prim<SmartGraph, int, FibHeap<SmartGraph::Node, int, 
    1.31 +    SmartGraph::NodeMap<int> > > prim_test(G, cap);
    1.32      prim_test.run();
    1.33    double post_time=currTime();
    1.34      
    1.35 @@ -31,8 +32,8 @@
    1.36  	    << post_time-pre_time << " sec"<< std::endl; 
    1.37   
    1.38    pre_time=currTime();
    1.39 -  Prim<ListGraph, int, BinHeap<ListGraph::Node, int, 
    1.40 -    ListGraph::NodeMap<int> > > prim_test2(G, cap);
    1.41 +  Prim<SmartGraph, int, BinHeap<SmartGraph::Node, int, 
    1.42 +    SmartGraph::NodeMap<int> > > prim_test2(G, cap);
    1.43    prim_test2.run();
    1.44    post_time=currTime();
    1.45