# HG changeset patch # User marci # Date 1080576000 0 # Node ID 509ba9f136d2337b3ab004e5e34b57adb4941ed1 # Parent 94bafec4f56fb88244aac60f17fb2d009393fcbb ResGraphWrapper partial improvement diff -r 94bafec4f56f -r 509ba9f136d2 src/work/edmonds_karp.h --- a/src/work/edmonds_karp.h Mon Mar 29 11:08:59 2004 +0000 +++ b/src/work/edmonds_karp.h Mon Mar 29 16:00:00 2004 +0000 @@ -1,6 +1,6 @@ // -*- c++ -*- -#ifndef EDMONDS_KARP_H -#define EDMONDS_KARP_H +#ifndef HUGO_EDMONDS_KARP_H +#define HUGO_EDMONDS_KARP_H #include #include @@ -1104,4 +1104,4 @@ } // namespace hugo -#endif //EDMONDS_KARP_H +#endif //HUGO_EDMONDS_KARP_H diff -r 94bafec4f56f -r 509ba9f136d2 src/work/marci/dimacs.h --- a/src/work/marci/dimacs.h Mon Mar 29 11:08:59 2004 +0000 +++ b/src/work/marci/dimacs.h Mon Mar 29 16:00:00 2004 +0000 @@ -1,6 +1,6 @@ // -*- c++ -*- -#ifndef DIMACS_H -#define DIMACS_H +#ifndef HUGO_DIMACS_H +#define HUGO_DIMACS_H #include #include @@ -57,4 +57,4 @@ } //namespace hugo -#endif //DIMACS_H +#endif //HUGO_DIMACS_H diff -r 94bafec4f56f -r 509ba9f136d2 src/work/marci/graph_wrapper.h --- a/src/work/marci/graph_wrapper.h Mon Mar 29 11:08:59 2004 +0000 +++ b/src/work/marci/graph_wrapper.h Mon Mar 29 16:00:00 2004 +0000 @@ -1,6 +1,6 @@ // -*- c++ -*- -#ifndef GRAPH_WRAPPER_H -#define GRAPH_WRAPPER_H +#ifndef HUGO_GRAPH_WRAPPER_H +#define HUGO_GRAPH_WRAPPER_H #include @@ -770,24 +770,26 @@ template class ResGraphWrapper { public: - typedef Graph BaseGraph; + //typedef Graph BaseGraph; typedef typename Graph::Node Node; typedef typename Graph::NodeIt NodeIt; private: typedef typename Graph::OutEdgeIt OldOutEdgeIt; typedef typename Graph::InEdgeIt OldInEdgeIt; protected: - const Graph* graph; + //const Graph* graph; + typedef TrivGraphWrapper GraphWrapper; + GraphWrapper gw; FlowMap* flow; const CapacityMap* capacity; public: ResGraphWrapper(const Graph& _G, FlowMap& _flow, const CapacityMap& _capacity) : - graph(&_G), flow(&_flow), capacity(&_capacity) { } + gw(_G), flow(&_flow), capacity(&_capacity) { } - void setGraph(const Graph& _graph) { graph = &_graph; } - const Graph& getGraph() const { return (*graph); } + //void setGraph(const Graph& _graph) { graph = &_graph; } + //const Graph& getGraph() const { return (*graph); } class Edge; class OutEdgeIt; @@ -829,12 +831,12 @@ OutEdgeIt(const Invalid& i) : Edge(i) { } private: OutEdgeIt(const ResGraphWrapper& resG, Node v) : Edge() { - resG.graph->first(out, v); - while( resG.graph->valid(out) && !(resG.free(out)>0) ) { resG.graph->next(out); } - if (!resG.graph->valid(out)) { + resG.gw.first(out, v); + while( resG.gw.valid(out) && !(resG.free(out)>0) ) { resG.gw.next(out); } + if (!resG.gw.valid(out)) { out_or_in=0; - resG.graph->first(in, v); - while( resG.graph->valid(in) && !(resG.free(in)>0) ) { resG.graph->next(in); } + resG.gw.first(in, v); + while( resG.gw.valid(in) && !(resG.free(in)>0) ) { resG.gw.next(in); } } } // public: @@ -864,23 +866,23 @@ //EdgeIt(const EdgeIt& e) : Edge(e), v(e.v) { } EdgeIt(const Invalid& i) : Edge(i) { } EdgeIt(const ResGraphWrapper& resG) : Edge() { - resG.graph->first(v); - if (resG.graph->valid(v)) resG.graph->first(out, v); else out=OldOutEdgeIt(INVALID); - while (resG.graph->valid(out) && !(resG.free(out)>0) ) { resG.graph->next(out); } - while (resG.graph->valid(v) && !resG.graph->valid(out)) { - resG.graph->next(v); - if (resG.graph->valid(v)) resG.graph->first(out, v); - while (resG.graph->valid(out) && !(resG.free(out)>0) ) { resG.graph->next(out); } + resG.gw.first(v); + if (resG.gw.valid(v)) resG.gw.first(out, v); else out=/*OldOutEdgeIt*/(INVALID); + while (resG.gw.valid(out) && !(resG.free(out)>0) ) { resG.gw.next(out); } + while (resG.gw.valid(v) && !resG.gw.valid(out)) { + resG.gw.next(v); + if (resG.gw.valid(v)) resG.gw.first(out, v); + while (resG.gw.valid(out) && !(resG.free(out)>0) ) { resG.gw.next(out); } } - if (!resG.graph->valid(out)) { + if (!resG.gw.valid(out)) { out_or_in=0; - resG.graph->first(v); - if (resG.graph->valid(v)) resG.graph->first(in, v); else in=OldInEdgeIt(INVALID); - while (resG.graph->valid(in) && !(resG.free(in)>0) ) { resG.graph->next(in); } - while (resG.graph->valid(v) && !resG.graph->valid(in)) { - resG.graph->next(v); - if (resG.graph->valid(v)) resG.graph->first(in, v); - while (resG.graph->valid(in) && !(resG.free(in)>0) ) { resG.graph->next(in); } + resG.gw.first(v); + if (resG.gw.valid(v)) resG.gw.first(in, v); else in=/*OldInEdgeIt*/(INVALID); + while (resG.gw.valid(in) && !(resG.free(in)>0) ) { resG.gw.next(in); } + while (resG.gw.valid(v) && !resG.gw.valid(in)) { + resG.gw.next(v); + if (resG.gw.valid(v)) resG.gw.first(in, v); + while (resG.gw.valid(in) && !(resG.free(in)>0) ) { resG.gw.next(in); } } } } @@ -917,7 +919,7 @@ // } }; - NodeIt& first(NodeIt& v) const { return graph->first(v); } + NodeIt& first(NodeIt& v) const { return gw.first(v); } OutEdgeIt& first(OutEdgeIt& e, Node v) const { e=OutEdgeIt(*this, v); return e; @@ -927,52 +929,52 @@ return e; } - NodeIt& next(NodeIt& n) const { return graph->next(n); } + NodeIt& next(NodeIt& n) const { return gw.next(n); } OutEdgeIt& next(OutEdgeIt& e) const { if (e.out_or_in) { - Node v=graph->aNode(e.out); - graph->next(e.out); - while( graph->valid(e.out) && !(free(e.out)>0) ) { graph->next(e.out); } - if (!graph->valid(e.out)) { + Node v=gw.aNode(e.out); + gw.next(e.out); + while( gw.valid(e.out) && !(free(e.out)>0) ) { gw.next(e.out); } + if (!gw.valid(e.out)) { e.out_or_in=0; - graph->first(e.in, v); - while( graph->valid(e.in) && !(free(e.in)>0) ) { graph->next(e.in); } + gw.first(e.in, v); + while( gw.valid(e.in) && !(free(e.in)>0) ) { gw.next(e.in); } } } else { - graph->next(e.in); - while( graph->valid(e.in) && !(free(e.in)>0) ) { graph->next(e.in); } + gw.next(e.in); + while( gw.valid(e.in) && !(free(e.in)>0) ) { gw.next(e.in); } } return e; } EdgeIt& next(EdgeIt& e) const { if (e.out_or_in) { - graph->next(e.out); - while (graph->valid(e.out) && !(free(e.out)>0) ) { graph->next(e.out); } - while (graph->valid(e.v) && !graph->valid(e.out)) { - graph->next(e.v); - if (graph->valid(e.v)) graph->first(e.out, e.v); - while (graph->valid(e.out) && !(free(e.out)>0) ) { graph->next(e.out); } + gw.next(e.out); + while (gw.valid(e.out) && !(free(e.out)>0) ) { gw.next(e.out); } + while (gw.valid(e.v) && !gw.valid(e.out)) { + gw.next(e.v); + if (gw.valid(e.v)) gw.first(e.out, e.v); + while (gw.valid(e.out) && !(free(e.out)>0) ) { gw.next(e.out); } } - if (!graph->valid(e.out)) { + if (!gw.valid(e.out)) { e.out_or_in=0; - graph->first(e.v); - if (graph->valid(e.v)) graph->first(e.in, e.v); else e.in=OldInEdgeIt(INVALID); - while (graph->valid(e.in) && !(free(e.in)>0) ) { graph->next(e.in); } - while (graph->valid(e.v) && !graph->valid(e.in)) { - graph->next(e.v); - if (graph->valid(e.v)) graph->first(e.in, e.v); - while (graph->valid(e.in) && !(free(e.in)>0) ) { graph->next(e.in); } + gw.first(e.v); + if (gw.valid(e.v)) gw.first(e.in, e.v); else e.in=/*OldInEdgeIt*/(INVALID); + while (gw.valid(e.in) && !(free(e.in)>0) ) { gw.next(e.in); } + while (gw.valid(e.v) && !gw.valid(e.in)) { + gw.next(e.v); + if (gw.valid(e.v)) gw.first(e.in, e.v); + while (gw.valid(e.in) && !(free(e.in)>0) ) { gw.next(e.in); } } } } else { - graph->next(e.in); - while (graph->valid(e.in) && !(free(e.in)>0) ) { graph->next(e.in); } - while (graph->valid(e.v) && !graph->valid(e.in)) { - graph->next(e.v); - if (graph->valid(e.v)) graph->first(e.in, e.v); - while (graph->valid(e.in) && !(free(e.in)>0) ) { graph->next(e.in); } + gw.next(e.in); + while (gw.valid(e.in) && !(free(e.in)>0) ) { gw.next(e.in); } + while (gw.valid(e.v) && !gw.valid(e.in)) { + gw.next(e.v); + if (gw.valid(e.v)) gw.first(e.in, e.v); + while (gw.valid(e.in) && !(free(e.in)>0) ) { gw.next(e.in); } } } return e; @@ -994,20 +996,20 @@ } Node tail(Edge e) const { - return ((e.out_or_in) ? graph->aNode(e.out) : graph->aNode(e.in)); } + return ((e.out_or_in) ? gw.aNode(e.out) : gw.aNode(e.in)); } Node head(Edge e) const { - return ((e.out_or_in) ? graph->bNode(e.out) : graph->bNode(e.in)); } + return ((e.out_or_in) ? gw.bNode(e.out) : gw.bNode(e.in)); } Node aNode(OutEdgeIt e) const { - return ((e.out_or_in) ? graph->aNode(e.out) : graph->aNode(e.in)); } + return ((e.out_or_in) ? gw.aNode(e.out) : gw.aNode(e.in)); } Node bNode(OutEdgeIt e) const { - return ((e.out_or_in) ? graph->bNode(e.out) : graph->bNode(e.in)); } + return ((e.out_or_in) ? gw.bNode(e.out) : gw.bNode(e.in)); } - int id(Node v) const { return graph->id(v); } + int id(Node v) const { return gw.id(v); } - bool valid(Node n) const { return graph->valid(n); } + bool valid(Node n) const { return gw.valid(n); } bool valid(Edge e) const { - return e.out_or_in ? graph->valid(e.out) : graph->valid(e.in); } + return e.out_or_in ? gw.valid(e.out) : gw.valid(e.in); } void augment(const Edge& e, Number a) const { if (e.out_or_in) @@ -1031,12 +1033,12 @@ return (flow->get(in)); } - template class NodeMap : public Graph::NodeMap { + template class NodeMap : public GraphWrapper::NodeMap { public: NodeMap(const ResGraphWrapper& _G) - : Graph::NodeMap(_G.getGraph()) { } + : GraphWrapper::NodeMap(_G.gw) { } NodeMap(const ResGraphWrapper& _G, - T a) : Graph::NodeMap(_G.getGraph(), a) { } + T a) : GraphWrapper::NodeMap(_G.gw, a) { } }; // template @@ -1051,10 +1053,10 @@ template class EdgeMap { - typename Graph::EdgeMap forward_map, backward_map; + typename GraphWrapper::EdgeMap forward_map, backward_map; public: - EdgeMap(const ResGraphWrapper& _G) : forward_map(_G.getGraph()), backward_map(_G.getGraph()) { } - EdgeMap(const ResGraphWrapper& _G, T a) : forward_map(_G.getGraph(), a), backward_map(_G.getGraph(), a) { } + EdgeMap(const ResGraphWrapper& _G) : forward_map(_G.gw), backward_map(_G.gw) { } + EdgeMap(const ResGraphWrapper& _G, T a) : forward_map(_G.gw, a), backward_map(_G.gw, a) { } void set(Edge e, T a) { if (e.out_or_in) forward_map.set(e.out, a); @@ -1127,8 +1129,8 @@ // return first(i, p); } //template I getNext(const I& i) const { - // return graph->getNext(i); } - //template I& next(I &i) const { return graph->next(i); } + // return gw.getNext(i); } + //template I& next(I &i) const { return gw.next(i); } template< typename It > It first() const { It e; first(e); return e; } @@ -1136,23 +1138,23 @@ template< typename It > It first(const Node& v) const { It e; first(e, v); return e; } - //Node head(const Edge& e) const { return graph->head(e); } - //Node tail(const Edge& e) const { return graph->tail(e); } + //Node head(const Edge& e) const { return gw.head(e); } + //Node tail(const Edge& e) const { return gw.tail(e); } //template bool valid(const I& i) const - // { return graph->valid(i); } + // { return gw.valid(i); } - //int nodeNum() const { return graph->nodeNum(); } - //int edgeNum() const { return graph->edgeNum(); } + //int nodeNum() const { return gw.nodeNum(); } + //int edgeNum() const { return gw.edgeNum(); } //template Node aNode(const I& e) const { - // return graph->aNode(e); } + // return gw.aNode(e); } //template Node bNode(const I& e) const { - // return graph->bNode(e); } + // return gw.bNode(e); } - //Node addNode() const { return graph->addNode(); } + //Node addNode() const { return gw.addNode(); } //Edge addEdge(const Node& tail, const Node& head) const { - // return graph->addEdge(tail, head); } + // return gw.addEdge(tail, head); } //void erase(const OutEdgeIt& e) { // first_out_edge(this->tail(e))=e; @@ -1162,9 +1164,9 @@ next(f); first_out_edges.set(this->tail(e), f); } - //template void erase(const I& i) const { graph->erase(i); } + //template void erase(const I& i) const { gw.erase(i); } - //void clear() const { graph->clear(); } + //void clear() const { gw.clear(); } template class NodeMap : public ResGraphWrapper::NodeMap { public: @@ -1209,7 +1211,7 @@ public: FilterGraphWrapper(const Graph& _G, FlowMap& _flow, const CapacityMap& _capacity) : - ErasingResGraphWrapper(_G, _flow, _capacity), dist(*this, graph->nodeNum()) { + ErasingResGraphWrapper(_G, _flow, _capacity), dist(*this, gw.nodeNum()) { } OutEdgeIt& first(OutEdgeIt& e, const Node& n) const { @@ -1248,13 +1250,13 @@ //void setGraph(Graph& _graph) { graph = &_graph; } //Graph& getGraph() const { return (*graph); } - //template I& first(I& i) const { return graph->first(i); } + //template I& first(I& i) const { return gw.first(i); } //template I& first(I& i, const P& p) const { - // return graph->first(i, p); } + // return gw.first(i, p); } //template I getNext(const I& i) const { - // return graph->getNext(i); } - //template I& next(I &i) const { return graph->next(i); } + // return gw.getNext(i); } + //template I& next(I &i) const { return gw.next(i); } template< typename It > It first() const { It e; first(e); return e; } @@ -1262,30 +1264,30 @@ template< typename It > It first(const Node& v) const { It e; first(e, v); return e; } - //Node head(const Edge& e) const { return graph->head(e); } - //Node tail(const Edge& e) const { return graph->tail(e); } + //Node head(const Edge& e) const { return gw.head(e); } + //Node tail(const Edge& e) const { return gw.tail(e); } //template bool valid(const I& i) const - // { return graph->valid(i); } + // { return gw.valid(i); } //template void setInvalid(const I &i); - //{ return graph->setInvalid(i); } + //{ return gw.setInvalid(i); } - //int nodeNum() const { return graph->nodeNum(); } - //int edgeNum() const { return graph->edgeNum(); } + //int nodeNum() const { return gw.nodeNum(); } + //int edgeNum() const { return gw.edgeNum(); } //template Node aNode(const I& e) const { - // return graph->aNode(e); } + // return gw.aNode(e); } //template Node bNode(const I& e) const { - // return graph->bNode(e); } + // return gw.bNode(e); } - //Node addNode() const { return graph->addNode(); } + //Node addNode() const { return gw.addNode(); } //Edge addEdge(const Node& tail, const Node& head) const { - // return graph->addEdge(tail, head); } + // return gw.addEdge(tail, head); } - //template void erase(const I& i) const { graph->erase(i); } + //template void erase(const I& i) const { gw.erase(i); } - //void clear() const { graph->clear(); } + //void clear() const { gw.clear(); } template class NodeMap : public ErasingResGraphWrapper::NodeMap { public: @@ -1341,10 +1343,10 @@ // typedef typename Graph::SymEdgeIt SymEdgeIt; // typedef typename Graph::EdgeIt EdgeIt; -// int nodeNum() const { return graph->nodeNum(); } -// int edgeNum() const { return graph->edgeNum(); } +// int nodeNum() const { return gw.nodeNum(); } +// int edgeNum() const { return gw.edgeNum(); } -// Node& first(Node& n) const { return graph->first(n); } +// Node& first(Node& n) const { return gw.first(n); } // // Edge and SymEdge is missing!!!! // // Edge <-> In/OutEdgeIt conversion is missing!!!! @@ -1353,70 +1355,70 @@ // OutEdgeIt& first(OutEdgeIt& e, const Node& n) const // { // e.n=n; -// graph->first(e.o,n); -// while(graph->valid(e.o) && fmap.get(e.o)>=himap.get(e.o)) -// graph->goNext(e.o); -// if(!graph->valid(e.o)) { -// graph->first(e.i,n); -// while(graph->valid(e.i) && fmap.get(e.i)<=lomap.get(e.i)) -// graph->goNext(e.i); +// gw.first(e.o,n); +// while(gw.valid(e.o) && fmap.get(e.o)>=himap.get(e.o)) +// gw.goNext(e.o); +// if(!gw.valid(e.o)) { +// gw.first(e.i,n); +// while(gw.valid(e.i) && fmap.get(e.i)<=lomap.get(e.i)) +// gw.goNext(e.i); // } // return e; // } // /* // OutEdgeIt &goNext(OutEdgeIt &e) // { -// if(graph->valid(e.o)) { -// while(graph->valid(e.o) && fmap.get(e.o)>=himap.get(e.o)) -// graph->goNext(e.o); -// if(graph->valid(e.o)) return e; -// else graph->first(e.i,e.n); +// if(gw.valid(e.o)) { +// while(gw.valid(e.o) && fmap.get(e.o)>=himap.get(e.o)) +// gw.goNext(e.o); +// if(gw.valid(e.o)) return e; +// else gw.first(e.i,e.n); // } // else { -// while(graph->valid(e.i) && fmap.get(e.i)<=lomap.get(e.i)) -// graph->goNext(e.i); +// while(gw.valid(e.i) && fmap.get(e.i)<=lomap.get(e.i)) +// gw.goNext(e.i); // return e; // } // } // OutEdgeIt Next(const OutEdgeIt &e) {OutEdgeIt t(e); return goNext(t);} // */ -// //bool valid(const OutEdgeIt e) { return graph->valid(e.o)||graph->valid(e.i);} +// //bool valid(const OutEdgeIt e) { return gw.valid(e.o)||gw.valid(e.i);} // //FIXME // InEdgeIt& first(InEdgeIt& e, const Node& n) const // { // e.n=n; -// graph->first(e.i,n); -// while(graph->valid(e.i) && fmap.get(e.i)>=himap.get(e.i)) -// graph->goNext(e.i); -// if(!graph->valid(e.i)) { -// graph->first(e.o,n); -// while(graph->valid(e.o) && fmap.get(e.o)<=lomap.get(e.o)) -// graph->goNext(e.o); +// gw.first(e.i,n); +// while(gw.valid(e.i) && fmap.get(e.i)>=himap.get(e.i)) +// gw.goNext(e.i); +// if(!gw.valid(e.i)) { +// gw.first(e.o,n); +// while(gw.valid(e.o) && fmap.get(e.o)<=lomap.get(e.o)) +// gw.goNext(e.o); // } // return e; // } // /* // InEdgeIt &goNext(InEdgeIt &e) // { -// if(graph->valid(e.i)) { -// while(graph->valid(e.i) && fmap.get(e.i)>=himap.get(e.i)) -// graph->goNext(e.i); -// if(graph->valid(e.i)) return e; -// else graph->first(e.o,e.n); +// if(gw.valid(e.i)) { +// while(gw.valid(e.i) && fmap.get(e.i)>=himap.get(e.i)) +// gw.goNext(e.i); +// if(gw.valid(e.i)) return e; +// else gw.first(e.o,e.n); // } // else { -// while(graph->valid(e.o) && fmap.get(e.o)<=lomap.get(e.o)) -// graph->goNext(e.o); +// while(gw.valid(e.o) && fmap.get(e.o)<=lomap.get(e.o)) +// gw.goNext(e.o); // return e; // } // } // InEdgeIt Next(const InEdgeIt &e) {InEdgeIt t(e); return goNext(t);} // */ -// //bool valid(const InEdgeIt e) { return graph->valid(e.i)||graph->valid(e.o);} +// //bool valid(const InEdgeIt e) { return gw.valid(e.i)||gw.valid(e.o);} -// //template I &goNext(I &i); { return graph->goNext(i); } -// //template I next(const I i); { return graph->goNext(i); } +// //template I &goNext(I &i); { return gw.goNext(i); } +// //template I next(const I i); { return gw.goNext(i); } // template< typename It > It first() const { // It e; first(e); return e; } @@ -1424,27 +1426,27 @@ // template< typename It > It first(Node v) const { // It e; first(e, v); return e; } -// Node head(const Edge& e) const { return graph->head(e); } -// Node tail(const Edge& e) const { return graph->tail(e); } +// Node head(const Edge& e) const { return gw.head(e); } +// Node tail(const Edge& e) const { return gw.tail(e); } // template Node aNode(const I& e) const { -// return graph->aNode(e); } +// return gw.aNode(e); } // template Node bNode(const I& e) const { -// return graph->bNode(e); } +// return gw.bNode(e); } // //template bool valid(const I i); -// //{ return graph->valid(i); } +// //{ return gw.valid(i); } // //template void setInvalid(const I &i); -// //{ return graph->setInvalid(i); } +// //{ return gw.setInvalid(i); } -// Node addNode() { return graph->addNode(); } +// Node addNode() { return gw.addNode(); } // Edge addEdge(const Node& tail, const Node& head) { -// return graph->addEdge(tail, head); } +// return gw.addEdge(tail, head); } -// template void erase(const I& i) { graph->erase(i); } +// template void erase(const I& i) { gw.erase(i); } -// void clear() { graph->clear(); } +// void clear() { gw.clear(); } // template class NodeMap : public Graph::NodeMap { }; // template class EdgeMap : public Graph::EdgeMap { }; @@ -1458,5 +1460,5 @@ } //namespace hugo -#endif //GRAPH_WRAPPER_H +#endif //HUGO_GRAPH_WRAPPER_H diff -r 94bafec4f56f -r 509ba9f136d2 src/work/marci/makefile --- a/src/work/marci/makefile Mon Mar 29 11:08:59 2004 +0000 +++ b/src/work/marci/makefile Mon Mar 29 16:00:00 2004 +0000 @@ -5,17 +5,19 @@ #CXXFLAGS = -W -Wall -ansi -pedantic -I. -I.. -I../alpar #LEDAROOT ?= /ledasrc/LEDA-4.1 BOOSTROOT ?= /home/marci/boost -INCLUDEDIRS ?= -I../../include -I.. -I. -I../{marci,jacint,alpar,klao,akos,athos} -I$(LEDAROOT)/incl -I$(BOOSTROOT) +INCLUDEDIRS ?= -I../../include -I.. -I../{marci,jacint,alpar,klao,akos,athos} -I$(BOOSTROOT) +LEDAINCLUDE ?= -I$(LEDAROOT)/incl CXXFLAGS = -g -O -W -Wall $(INCLUDEDIRS) -ansi -pedantic -LEDABINARIES = lg_vs_sg leda_graph_demo leda_bfs_dfs -BINARIES = edmonds_karp_demo max_bipartite_matching_demo +LEDABINARIES = lg_vs_sg leda_graph_demo leda_bfs_dfs max_bipartite_matching_demo +BINARIES = edmonds_karp_demo #preflow_demo_boost edmonds_karp_demo_boost preflow_demo_jacint preflow_demo_athos edmonds_karp_demo_alpar preflow_demo_leda all: $(BINARIES) .depend dep depend: -g++ $(INCLUDEDIRS) -M $(BINARIES:=.cc) > .depend #2>/dev/null +# -g++ $(INCLUDEDIRS) $(LEDAINCLUDE) -M $(LEDABINARIES:=.cc) >> .depend #2>/dev/null @@ -41,8 +43,8 @@ $(CXX3) -Wall -O -L$(LEDAROOT) -o leda_bfs_dfs leda_bfs_dfs.o -lG -lL -lm edmonds_karp_demo: - $(CXX3) $(CXXFLAGS) -g -I. -I.. -o edmonds_karp_demo edmonds_karp_demo.cc - $(CXX3) $(CXXFLAGS) -g -pg -I. -I.. -o edmonds_karp_demo_prof edmonds_karp_demo.cc + $(CXX3) $(CXXFLAGS) -o edmonds_karp_demo edmonds_karp_demo.cc +# $(CXX3) $(CXXFLAGS) -pg -o edmonds_karp_demo_prof edmonds_karp_demo.cc lg_vs_sg: $(CXX3) $(CXXFLAGS) -g -I. -I.. -o lg_vs_sg lg_vs_sg.cc diff -r 94bafec4f56f -r 509ba9f136d2 src/work/marci/time_measure.h --- a/src/work/marci/time_measure.h Mon Mar 29 11:08:59 2004 +0000 +++ b/src/work/marci/time_measure.h Mon Mar 29 16:00:00 2004 +0000 @@ -1,6 +1,6 @@ // -*- c++ -*- -#ifndef TIME_MEASURE_H -#define TIME_MEASURE_H +#ifndef HUGO_TIME_MEASURE_H +#define HUGO_TIME_MEASURE_H #include #include @@ -127,4 +127,4 @@ return os; } -#endif //TIME_MEASURE_H +#endif //HUGO_TIME_MEASURE_H