summaryrefslogtreecommitdiff
path: root/ot/lp/network_simplex_simple.h
diff options
context:
space:
mode:
authorGard Spreemann <gspr@nonempty.org>2020-07-09 08:50:11 +0200
committerGard Spreemann <gspr@nonempty.org>2020-07-09 08:50:11 +0200
commit616c6039614e96b6cfd88eb7db25ce11c7302c30 (patch)
treea745ec24604f660b256dbaee214affa497c9c21e /ot/lp/network_simplex_simple.h
parentd62f05daf348b4e554056f298c66cbd64f5e3c6e (diff)
parenta16b9471d7114ec08977479b7249efe747702b97 (diff)
Merge branch 'dfsg/latest' into debian/sid
Diffstat (limited to 'ot/lp/network_simplex_simple.h')
-rw-r--r--ot/lp/network_simplex_simple.h7
1 files changed, 3 insertions, 4 deletions
diff --git a/ot/lp/network_simplex_simple.h b/ot/lp/network_simplex_simple.h
index 7c6a4ce..5d93040 100644
--- a/ot/lp/network_simplex_simple.h
+++ b/ot/lp/network_simplex_simple.h
@@ -686,7 +686,7 @@ namespace lemon {
/// \see resetParams(), reset()
ProblemType run() {
#if DEBUG_LVL>0
- std::cout << "OPTIMAL = " << OPTIMAL << "\nINFEASIBLE = " << INFEASIBLE << "\nUNBOUNDED = " << UNBOUNDED << "\nMAX_ITER_REACHED" << MAX_ITER_REACHED\n";
+ std::cout << "OPTIMAL = " << OPTIMAL << "\nINFEASIBLE = " << INFEASIBLE << "\nUNBOUNDED = " << UNBOUNDED << "\nMAX_ITER_REACHED" << MAX_ITER_REACHED << "\n" ;
#endif
if (!init()) return INFEASIBLE;
@@ -875,7 +875,7 @@ namespace lemon {
c += Number(it->second) * Number(_cost[it->first]);
return c;*/
- for (int i=0; i<_flow.size(); i++)
+ for (unsigned long i=0; i<_flow.size(); i++)
c += _flow[i] * Number(_cost[i]);
return c;
@@ -1257,7 +1257,7 @@ namespace lemon {
u = w;
}
_pred[u_in] = in_arc;
- _forward[u_in] = (u_in == _source[in_arc]);
+ _forward[u_in] = ((unsigned int)u_in == _source[in_arc]);
_succ_num[u_in] = old_succ_num;
// Set limits for updating _last_succ form v_in and v_out
@@ -1418,7 +1418,6 @@ namespace lemon {
template <typename PivotRuleImpl>
ProblemType start() {
PivotRuleImpl pivot(*this);
- double prevCost=-1;
ProblemType retVal = OPTIMAL;
// Perform heuristic initial pivots