# HG changeset patch # User deba # Date 1195335661 0 # Node ID caa640aa9a7e651ed2389816164ff5f3331467b3 # Parent 57143c09dc20a4b6d65d0c58f709331be66dfb72 Changing max flow interface diff -r 57143c09dc20 -r caa640aa9a7e lemon/min_cost_max_flow.h --- a/lemon/min_cost_max_flow.h Sat Nov 17 20:58:11 2007 +0000 +++ b/lemon/min_cost_max_flow.h Sat Nov 17 21:41:01 2007 +0000 @@ -92,7 +92,7 @@ /// \brief The edge map of the found flow. FlowMap flow; - typedef Preflow PreflowImpl; + typedef Preflow PreflowImpl; /// \brief \ref lemon::Preflow "Preflow" class for finding the /// maximum flow value. PreflowImpl preflow; @@ -114,7 +114,7 @@ Node _s, Node _t ) : graph(_graph), capacity(_capacity), cost(_cost), source(_s), target(_t), flow(_graph), - preflow(_graph, _s, _t, _capacity, flow) + preflow(_graph, _capacity, _s, _t) {} /// \brief Returns a const reference to the flow map. @@ -141,7 +141,8 @@ /// \brief Runs the algorithm. void run() { - preflow.phase1(); + preflow.flowMap(flow); + preflow.runMinCut(); MinCostFlowImpl mcf_impl( graph, capacity, cost, source, target, preflow.flowValue() ); mcf_impl.run();