[Lemon-commits] deba: r3397 - lemon/trunk/lemon

Lemon SVN svn at lemon.cs.elte.hu
Wed Nov 21 19:19:20 CET 2007


Author: deba
Date: Wed Nov 21 19:19:20 2007
New Revision: 3397

Modified:
   lemon/trunk/lemon/elevator.h

Log:
Better solution



Modified: lemon/trunk/lemon/elevator.h
==============================================================================
--- lemon/trunk/lemon/elevator.h	(original)
+++ lemon/trunk/lemon/elevator.h	Wed Nov 21 19:19:20 2007
@@ -383,11 +383,12 @@
     ///Mark the node as it did not reach the max level
     
     ///Mark the node as it did not reach the max level. It sets the
-    ///level of the node to a low value, which is not connected to the
-    ///real levels of elevator. The node should be lifted previously
-    ///to the top level.
+    ///level to the under the max level value. The node will be never
+    ///more activated because the push operation from the maximum
+    ///level is forbidden in the push-relabel algorithms. The node
+    ///should be lifted previously to the top level.
     void markToBottom(Item i) {
-      _level[i] = - _max_level;
+      _level[i] = _max_level - 1;
     }
     
     ///Lift all nodes on and above a level to the top (and deactivate them).
@@ -899,11 +900,12 @@
     ///Mark the node as it did not reach the max level
     
     ///Mark the node as it did not reach the max level. It sets the
-    ///level of the node to a low value, which is not connected to the
-    ///real levels of elevator. The node should be lifted previously
-    ///to the top level.
+    ///level to the under the max level value. The node will be never
+    ///more activated because the push operation from the maximum
+    ///level is forbidden in the push-relabel algorithms. The node
+    ///should be lifted previously to the top level.
     void markToBottom(Item i) {
-      _level[i] = - _max_level;
+      _level[i] = _max_level - 1;
     }
 
     ///Lift all nodes on and above a level to the top (and deactivate them).



More information about the Lemon-commits mailing list