Changes in lemon/cost_scaling.h [1298:a78e5b779b69:1297:c0c2f5c87aa6] in lemon
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
lemon/cost_scaling.h
r1298 r1297 3 3 * This file is a part of LEMON, a generic C++ optimization library. 4 4 * 5 * Copyright (C) 2003-201 35 * Copyright (C) 2003-2010 6 6 * Egervary Jeno Kombinatorikus Optimalizalasi Kutatocsoport 7 7 * (Egervary Research Group on Combinatorial Optimization, EGRES). … … 92 92 /// \ref CostScaling implements a cost scaling algorithm that performs 93 93 /// push/augment and relabel operations for finding a \ref min_cost_flow 94 /// "minimum cost flow" \cite amo93networkflows, 95 /// \cite goldberg90approximation, 96 /// \cite goldberg97efficient, \cite bunnagel98efficient. 94 /// "minimum cost flow" \ref amo93networkflows, \ref goldberg90approximation, 95 /// \ref goldberg97efficient, \ref bunnagel98efficient. 97 96 /// It is a highly efficient primal-dual solution method, which 98 97 /// can be viewed as the generalization of the \ref Preflow 99 98 /// "preflow push-relabel" algorithm for the maximum flow problem. 100 /// It is a polynomial algorithm, its running time complexity is101 /// \f$O(n^2m\log(nK))\f$, where <i>K</i> denotes the maximum arc cost.102 99 /// 103 100 /// In general, \ref NetworkSimplex and \ref CostScaling are the fastest … … 154 151 typedef typename TR::LargeCost LargeCost; 155 152 156 /// \brief The \ref lemon::CostScalingDefaultTraits "traits class" 157 /// of the algorithm 153 /// The \ref CostScalingDefaultTraits "traits class" of the algorithm 158 154 typedef TR Traits; 159 155 … … 215 211 typedef std::vector<LargeCost> LargeCostVector; 216 212 typedef std::vector<char> BoolVector; 217 // Note: vector<char> is used instead of vector<bool> 218 // for efficiency reasons 213 // Note: vector<char> is used instead of vector<bool> for efficiency reasons 219 214 220 215 private: … … 672 667 /// 673 668 /// This function returns the total cost of the found flow. 674 /// Its complexity is O( m).669 /// Its complexity is O(e). 675 670 /// 676 671 /// \note The return type of the function can be specified as a … … 906 901 return OPTIMAL; 907 902 } 908 903 909 904 // Check if the upper bound is greater than or equal to the lower bound 910 905 // on each forward arc. … … 1287 1282 _buckets[r] = _bucket_next[u]; 1288 1283 1289 // Search the incom ing arcs of u1284 // Search the incomming arcs of u 1290 1285 LargeCost pi_u = _pi[u]; 1291 1286 int last_out = _first_out[u+1];
Note: See TracChangeset
for help on using the changeset viewer.