Changing first to iterators.
4 #include <list_graph.h>
5 #include <lemon/dimacs.h>
6 #include <lemon/time_measure.h>
7 #include "minlengthpaths.h"
8 //#include <time_measure.h>
10 using namespace lemon;
12 // Use a DIMACS max flow file as stdin.
13 // read_dimacs_demo < dimacs_max_flow_file
14 int main(int argc, char ** argv) {
15 typedef ListGraph Graph;
17 typedef Graph::Node Node;
18 //typedef Graph::EachEdgeIt EachEdgeIt;
22 Graph::EdgeMap<int> cap(G);
23 readDimacs(std::cin, G, cap, s, t);
25 std::cout << "Minlengthpaths demo (ATHOS)..." << std::endl;
26 //Graph::EdgeMap<int> flow(G); //0 flow
28 // double pre_time=currTime();
33 MinLengthPaths<Graph, Graph::EdgeMap<int> >
37 std::cout << "Number of found paths: " << surb_test.run(s,t,k) << std::endl;
38 std::cout << "elapsed time: " << ts << std::endl;
40 std::cout << "Total length of found paths: " << surb_test.totalLength() << std::endl;
41 //std::cout << (surb_test.checkComplementarySlackness() ? "OK (compl. slackn.)." : "Problem (compl. slackn.)!!!") << std::endl;
43 //preflow_push<Graph, int> max_flow_test(G, s, t, cap);
44 //int flow_value=max_flow_test.run();
46 //double post_time=currTime();
48 //std::cout << "elapsed time: " << post_time-pre_time << " sec"<< std::endl;
49 //std::cout << "flow value: "<< flow_value << std::endl;