Better solution
authordeba
Wed, 21 Nov 2007 18:19:20 +0000
changeset 25206148e83636b9
parent 2519 a7376f7ed899
child 2521 05c0ba99cc27
Better solution
lemon/elevator.h
     1.1 --- a/lemon/elevator.h	Wed Nov 21 13:35:10 2007 +0000
     1.2 +++ b/lemon/elevator.h	Wed Nov 21 18:19:20 2007 +0000
     1.3 @@ -383,11 +383,12 @@
     1.4      ///Mark the node as it did not reach the max level
     1.5      
     1.6      ///Mark the node as it did not reach the max level. It sets the
     1.7 -    ///level of the node to a low value, which is not connected to the
     1.8 -    ///real levels of elevator. The node should be lifted previously
     1.9 -    ///to the top level.
    1.10 +    ///level to the under the max level value. The node will be never
    1.11 +    ///more activated because the push operation from the maximum
    1.12 +    ///level is forbidden in the push-relabel algorithms. The node
    1.13 +    ///should be lifted previously to the top level.
    1.14      void markToBottom(Item i) {
    1.15 -      _level[i] = - _max_level;
    1.16 +      _level[i] = _max_level - 1;
    1.17      }
    1.18      
    1.19      ///Lift all nodes on and above a level to the top (and deactivate them).
    1.20 @@ -899,11 +900,12 @@
    1.21      ///Mark the node as it did not reach the max level
    1.22      
    1.23      ///Mark the node as it did not reach the max level. It sets the
    1.24 -    ///level of the node to a low value, which is not connected to the
    1.25 -    ///real levels of elevator. The node should be lifted previously
    1.26 -    ///to the top level.
    1.27 +    ///level to the under the max level value. The node will be never
    1.28 +    ///more activated because the push operation from the maximum
    1.29 +    ///level is forbidden in the push-relabel algorithms. The node
    1.30 +    ///should be lifted previously to the top level.
    1.31      void markToBottom(Item i) {
    1.32 -      _level[i] = - _max_level;
    1.33 +      _level[i] = _max_level - 1;
    1.34      }
    1.35  
    1.36      ///Lift all nodes on and above a level to the top (and deactivate them).