Index: gtags
===================================================================
--- .hgtags	(revision 898)
+++ 	(revision )
@@ -1,2 +1,0 @@
-3ed8f7c8bed8f51aecdc8395aa11af2f1fa12d9f r1.2
-ffc2d2559fc916e90c3f000582a2d4761d229d44 r1.2.1
Index: CMakeLists.txt
===================================================================
--- CMakeLists.txt	(revision 905)
+++ CMakeLists.txt	(revision 744)
@@ -3,7 +3,4 @@
 SET(PROJECT_NAME "LEMON")
 PROJECT(${PROJECT_NAME})
-
-INCLUDE(FindPythonInterp)
-INCLUDE(FindWget)
 
 IF(EXISTS ${PROJECT_SOURCE_DIR}/cmake/version.cmake)
@@ -12,11 +9,4 @@
   SET(LEMON_VERSION $ENV{LEMON_VERSION} CACHE STRING "LEMON version string.")
 ELSE()
-  EXECUTE_PROCESS(
-    COMMAND ${PYTHON_EXECUTABLE} ./scripts/chg-len.py
-    WORKING_DIRECTORY ${PROJECT_SOURCE_DIR}
-    OUTPUT_VARIABLE HG_REVISION_PATH
-    ERROR_QUIET
-    OUTPUT_STRIP_TRAILING_WHITESPACE
-  )
   EXECUTE_PROCESS(
     COMMAND hg id -i
@@ -27,13 +17,7 @@
   )
   IF(HG_REVISION STREQUAL "")
-    SET(HG_REVISION_ID "hg-tip")
-  ELSE()
-    IF(HG_REVISION_PATH STREQUAL "")
-      SET(HG_REVISION_ID ${HG_REVISION})
-    ELSE()
-      SET(HG_REVISION_ID ${HG_REVISION_PATH}.${HG_REVISION})
-    ENDIF()
+    SET(HG_REVISION "hg-tip")
   ENDIF()
-  SET(LEMON_VERSION ${HG_REVISION_ID} CACHE STRING "LEMON version string.")
+  SET(LEMON_VERSION ${HG_REVISION} CACHE STRING "LEMON version string.")
 ENDIF()
 
@@ -48,67 +32,4 @@
 FIND_PACKAGE(COIN)
 
-IF(DEFINED ENV{LEMON_CXX_WARNING})
-  SET(CXX_WARNING $ENV{LEMON_CXX_WARNING})
-ELSE()
-  IF(CMAKE_COMPILER_IS_GNUCXX)
-    SET(CXX_WARNING "-Wall -W -Wunused -Wformat=2 -Wctor-dtor-privacy -Wnon-virtual-dtor -Wno-char-subscripts -Wwrite-strings -Wno-char-subscripts -Wreturn-type -Wcast-qual -Wcast-align -Wsign-promo -Woverloaded-virtual -ansi -fno-strict-aliasing -Wold-style-cast -Wno-unknown-pragmas")
-    SET(CMAKE_CXX_FLAGS_DEBUG CACHE STRING "-ggdb")
-    SET(CMAKE_C_FLAGS_DEBUG CACHE STRING "-ggdb")
-  ELSEIF(MSVC)
-    # This part is unnecessary 'casue the same is set by the lemon/core.h.
-    # Still keep it as an example.
-    SET(CXX_WARNING "/wd4250 /wd4355 /wd4503 /wd4800 /wd4996")
-    # Suppressed warnings:
-    # C4250: 'class1' : inherits 'class2::member' via dominance
-    # C4355: 'this' : used in base member initializer list
-    # C4503: 'function' : decorated name length exceeded, name was truncated
-    # C4800: 'type' : forcing value to bool 'true' or 'false'
-    #        (performance warning)
-    # C4996: 'function': was declared deprecated
-  ELSE()
-    SET(CXX_WARNING "-Wall -W")
-  ENDIF()
-ENDIF()
-SET(LEMON_CXX_WARNING_FLAGS ${CXX_WARNING} CACHE STRING "LEMON warning flags.")
-
-SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${LEMON_CXX_WARNING_FLAGS}")
-
-SET( CMAKE_CXX_FLAGS_MAINTAINER "-Werror -ggdb" CACHE STRING
-    "Flags used by the C++ compiler during maintainer builds."
-    FORCE )
-SET( CMAKE_C_FLAGS_MAINTAINER "-Werror" CACHE STRING
-    "Flags used by the C compiler during maintainer builds."
-    FORCE )
-SET( CMAKE_EXE_LINKER_FLAGS_MAINTAINER
-    "-Wl,--warn-unresolved-symbols,--warn-once" CACHE STRING
-    "Flags used for linking binaries during maintainer builds."
-    FORCE )
-SET( CMAKE_SHARED_LINKER_FLAGS_MAINTAINER
-    "-Wl,--warn-unresolved-symbols,--warn-once" CACHE STRING
-    "Flags used by the shared libraries linker during maintainer builds."
-    FORCE )
-MARK_AS_ADVANCED(
-    CMAKE_CXX_FLAGS_MAINTAINER
-    CMAKE_C_FLAGS_MAINTAINER
-    CMAKE_EXE_LINKER_FLAGS_MAINTAINER
-    CMAKE_SHARED_LINKER_FLAGS_MAINTAINER )
-
-IF(CMAKE_CONFIGURATION_TYPES)
-  LIST(APPEND CMAKE_CONFIGURATION_TYPES Maintainer)
-  LIST(REMOVE_DUPLICATES CMAKE_CONFIGURATION_TYPES)
-  SET(CMAKE_CONFIGURATION_TYPES "${CMAKE_CONFIGURATION_TYPES}" CACHE STRING
-      "Add the configurations that we need"
-      FORCE)
- endif()
-
-IF(NOT CMAKE_BUILD_TYPE)
-  SET(CMAKE_BUILD_TYPE "Release")
-ENDIF()
-
-SET( CMAKE_BUILD_TYPE "${CMAKE_BUILD_TYPE}" CACHE STRING
-    "Choose the type of build, options are: None(CMAKE_CXX_FLAGS or CMAKE_C_FLAGS used) Debug Release RelWithDebInfo MinSizeRel Maintainer."
-    FORCE )
-
-
 INCLUDE(CheckTypeSize)
 CHECK_TYPE_SIZE("long long" LONG_LONG)
@@ -118,10 +39,4 @@
 
 ENABLE_TESTING()
-
-IF(${CMAKE_BUILD_TYPE} STREQUAL "Maintainer")
-  ADD_CUSTOM_TARGET(check ALL COMMAND ${CMAKE_CTEST_COMMAND})
-ELSE()
-  ADD_CUSTOM_TARGET(check COMMAND ${CMAKE_CTEST_COMMAND})
-ENDIF()
 
 ADD_SUBDIRECTORY(lemon)
@@ -150,5 +65,5 @@
 ENDIF()
 
-IF(${CMAKE_SOURCE_DIR} STREQUAL ${PROJECT_SOURCE_DIR})
+IF(${CMAKE_SOURCE_DIR} STREQUAL ${PROJECT_SOURCE_DIR} AND WIN32)
   SET(CPACK_PACKAGE_NAME ${PROJECT_NAME})
   SET(CPACK_PACKAGE_VENDOR "EGRES")
Index: LICENSE
===================================================================
--- LICENSE	(revision 880)
+++ LICENSE	(revision 553)
@@ -2,5 +2,5 @@
 copyright/license.
 
-Copyright (C) 2003-2010 Egervary Jeno Kombinatorikus Optimalizalasi
+Copyright (C) 2003-2009 Egervary Jeno Kombinatorikus Optimalizalasi
 Kutatocsoport (Egervary Combinatorial Optimization Research Group,
 EGRES).
Index: NEWS
===================================================================
--- NEWS	(revision 897)
+++ NEWS	(revision 665)
@@ -1,94 +1,2 @@
-2010-10-21 Version 1.2.1 released
-
-        Bugfix release.
-
-        #366: Fix Pred[Matrix]MapPath::empty()
-        #371: Bug fix in (di)graphCopy()
-              The target graph is cleared before adding nodes and arcs/edges.
-
-        #364: Add missing UndirectedTags
-        #368: Fix the usage of std::numeric_limits<>::min() in Network Simplex
-        #372: Fix a critical bug in preflow
-
-2010-03-19 Version 1.2 released
-
-        This is major feature release
-
-        * New algorithms
-          * Bellman-Ford algorithm (#51)
-          * Minimum mean cycle algorithms (#179)
-            * Karp, Hartman-Orlin and Howard algorithms
-          * New minimum cost flow algorithms (#180)
-            * Cost Scaling algorithms
-            * Capacity Scaling algorithm
-            * Cycle-Canceling algorithms
-          * Planarity related algorithms (#62)
-            * Planarity checking algorithm
-            * Planar embedding algorithm
-            * Schnyder's planar drawing algorithm
-            * Coloring planar graphs with five or six colors
-          * Fractional matching algorithms (#314)
-        * New data structures
-          * StaticDigraph structure (#68)
-          * Several new priority queue structures (#50, #301)
-            * Fibonacci, Radix, Bucket, Pairing, Binomial
-              D-ary and fourary heaps (#301)
-          * Iterable map structures (#73)
-        * Other new tools and functionality
-          * Map utility functions (#320)
-          * Reserve functions are added to ListGraph and SmartGraph (#311)
-          * A resize() function is added to HypercubeGraph (#311)
-          * A count() function is added to CrossRefMap (#302)
-          * Support for multiple targets in Suurballe using fullInit() (#181)
-          * Traits class and named parameters for Suurballe (#323)
-          * Separate reset() and resetParams() functions in NetworkSimplex
-            to handle graph changes (#327)
-          * tolerance() functions are added to HaoOrlin (#306)
-        * Implementation improvements
-          * Improvements in weighted matching algorithms (#314)
-            * Jumpstart initialization
-          * ArcIt iteration is based on out-arc lists instead of in-arc lists
-            in ListDigraph (#311)
-          * Faster add row operation in CbcMip (#203)
-          * Better implementation for split() in ListDigraph (#311)
-          * ArgParser can also throw exception instead of exit(1) (#332)
-        * Miscellaneous
-          * A simple interactive bootstrap script
-          * Doc improvements (#62,#180,#299,#302,#303,#304,#307,#311,#331,#315,
-                #316,#319)
-            * BibTeX references in the doc (#184)
-          * Optionally use valgrind when running tests
-          * Also check ReferenceMapTag in concept checks (#312)
-          * dimacs-solver uses long long type by default.
-        * Several bugfixes (compared to release 1.1):
-          #295: Suppress MSVC warnings using pragmas
-          ----: Various CMAKE related improvements
-                * Remove duplications from doc/CMakeLists.txt
-                * Rename documentation install folder from 'docs' to 'html'
-                * Add tools/CMakeLists.txt to the tarball
-                * Generate and install LEMONConfig.cmake
-                * Change the label of the html project in Visual Studio
-                * Fix the check for the 'long long' type
-                * Put the version string into config.h
-                * Minor CMake improvements
-                * Set the version to 'hg-tip' if everything fails
-          #311: Add missing 'explicit' keywords
-          #302: Fix the implementation and doc of CrossRefMap
-          #308: Remove duplicate list_graph.h entry from source list
-          #307: Bugfix in Preflow and Circulation
-          #305: Bugfix and extension in the rename script
-          #312: Also check ReferenceMapTag in concept checks
-          #250: Bugfix in pathSource() and pathTarget()
-          #321: Use pathCopy(from,to) instead of copyPath(to,from)
-          #322: Distribure LEMONConfig.cmake.in
-          #330: Bug fix in map_extender.h
-          #336: Fix the date field comment of graphToEps() output
-          #323: Bug fix in Suurballe
-          #335: Fix clear() function in ExtendFindEnum
-          #337: Use void* as the LPX object pointer
-          #317: Fix (and improve) error message in mip_test.cc
-                Remove unnecessary OsiCbc dependency
-          #356: Allow multiple executions of weighted matching algorithms (#356)
-
 2009-05-13 Version 1.1 released
 
@@ -165,5 +73,5 @@
           ----: Add missing unistd.h include to time_measure.h
           #204: Compilation bug fixed in graph_to_eps.h with VS2005
-          #214,#215: windows.h should never be included by LEMON headers
+          #214,#215: windows.h should never be included by lemon headers
           #230: Build systems check the availability of 'long long' type
           #229: Default implementation of Tolerance<> is used for integer types
@@ -187,50 +95,50 @@
 2008-10-13 Version 1.0 released
 
-        This is the first stable release of LEMON. Compared to the 0.x
-        release series, it features a considerably smaller but more
-        matured set of tools. The API has also completely revised and
-        changed in several places.
+	This is the first stable release of LEMON. Compared to the 0.x
+	release series, it features a considerably smaller but more
+	matured set of tools. The API has also completely revised and
+	changed in several places.
 
-        * The major name changes compared to the 0.x series (see the
+	* The major name changes compared to the 0.x series (see the
           Migration Guide in the doc for more details)
           * Graph -> Digraph, UGraph -> Graph
           * Edge -> Arc, UEdge -> Edge
-          * source(UEdge)/target(UEdge) -> u(Edge)/v(Edge)
-        * Other improvements
-          * Better documentation
-          * Reviewed and cleaned up codebase
-          * CMake based build system (along with the autotools based one)
-        * Contents of the library (ported from 0.x)
-          * Algorithms
-            * breadth-first search (bfs.h)
-            * depth-first search (dfs.h)
-            * Dijkstra's algorithm (dijkstra.h)
-            * Kruskal's algorithm (kruskal.h)
-          * Data structures
-            * graph data structures (list_graph.h, smart_graph.h)
-            * path data structures (path.h)
-            * binary heap data structure (bin_heap.h)
-            * union-find data structures (unionfind.h)
-            * miscellaneous property maps (maps.h)
-            * two dimensional vector and bounding box (dim2.h)
+	  * source(UEdge)/target(UEdge) -> u(Edge)/v(Edge)
+	* Other improvements
+	  * Better documentation
+	  * Reviewed and cleaned up codebase
+	  * CMake based build system (along with the autotools based one)
+	* Contents of the library (ported from 0.x)
+	  * Algorithms
+       	    * breadth-first search (bfs.h)
+       	    * depth-first search (dfs.h)
+       	    * Dijkstra's algorithm (dijkstra.h)
+       	    * Kruskal's algorithm (kruskal.h)
+    	  * Data structures
+       	    * graph data structures (list_graph.h, smart_graph.h)
+       	    * path data structures (path.h)
+       	    * binary heap data structure (bin_heap.h)
+       	    * union-find data structures (unionfind.h)
+       	    * miscellaneous property maps (maps.h)
+       	    * two dimensional vector and bounding box (dim2.h)
           * Concepts
-            * graph structure concepts (concepts/digraph.h, concepts/graph.h,
+       	    * graph structure concepts (concepts/digraph.h, concepts/graph.h,
               concepts/graph_components.h)
-            * concepts for other structures (concepts/heap.h, concepts/maps.h,
-              concepts/path.h)
-          * Tools
-            * Mersenne twister random number generator (random.h)
-            * tools for measuring cpu and wall clock time (time_measure.h)
-            * tools for counting steps and events (counter.h)
-            * tool for parsing command line arguments (arg_parser.h)
-            * tool for visualizing graphs (graph_to_eps.h)
-            * tools for reading and writing data in LEMON Graph Format
+       	    * concepts for other structures (concepts/heap.h, concepts/maps.h,
+	      concepts/path.h)
+    	  * Tools
+       	    * Mersenne twister random number generator (random.h)
+       	    * tools for measuring cpu and wall clock time (time_measure.h)
+       	    * tools for counting steps and events (counter.h)
+       	    * tool for parsing command line arguments (arg_parser.h)
+       	    * tool for visualizing graphs (graph_to_eps.h)
+       	    * tools for reading and writing data in LEMON Graph Format
               (lgf_reader.h, lgf_writer.h)
             * tools to handle the anomalies of calculations with
-              floating point numbers (tolerance.h)
+	      floating point numbers (tolerance.h)
             * tools to manage RGB colors (color.h)
-          * Infrastructure
-            * extended assertion handling (assert.h)
-            * exception classes and error handling (error.h)
-            * concept checking (concept_check.h)
-            * commonly used mathematical constants (math.h)
+    	  * Infrastructure
+       	    * extended assertion handling (assert.h)
+       	    * exception classes and error handling (error.h)
+      	    * concept checking (concept_check.h)
+       	    * commonly used mathematical constants (math.h)
Index: configure.ac
===================================================================
--- configure.ac	(revision 908)
+++ configure.ac	(revision 793)
@@ -115,5 +115,5 @@
 dnl Add dependencies on files generated by configure.
 AC_SUBST([CONFIG_STATUS_DEPENDENCIES],
-  ['$(top_srcdir)/doc/Doxyfile.in $(top_srcdir)/doc/mainpage.dox.in $(top_srcdir)/lemon/lemon.pc.in $(top_srcdir)/cmake/version.cmake.in'])
+  ['$(top_srcdir)/doc/Doxyfile.in $(top_srcdir)/lemon/lemon.pc.in $(top_srcdir)/cmake/version.cmake.in'])
 
 AC_CONFIG_FILES([
@@ -122,5 +122,4 @@
 cmake/version.cmake
 doc/Doxyfile
-doc/mainpage.dox
 lemon/lemon.pc
 ])
Index: doc/CMakeLists.txt
===================================================================
--- doc/CMakeLists.txt	(revision 908)
+++ doc/CMakeLists.txt	(revision 865)
@@ -4,15 +4,7 @@
 SET(abs_top_builddir ${PROJECT_BINARY_DIR})
 
-SET(LEMON_DOC_SOURCE_BROWSER "NO" CACHE STRING "Include source into the doc (YES/NO).")
-
 CONFIGURE_FILE(
   ${PROJECT_SOURCE_DIR}/doc/Doxyfile.in
   ${PROJECT_BINARY_DIR}/doc/Doxyfile
-  @ONLY
-)
-
-CONFIGURE_FILE(
-  ${PROJECT_SOURCE_DIR}/doc/mainpage.dox.in
-  ${PROJECT_BINARY_DIR}/doc/mainpage.dox
   @ONLY
 )
@@ -61,14 +53,2 @@
 
 ENDIF()
-
-IF(WGET_FOUND)
-ADD_CUSTOM_TARGET(update-external-tags
-  COMMAND ${CMAKE_COMMAND} -E make_directory dl
-  # COMMAND ${CMAKE_COMMAND} -E copy libstdc++.tag dl
-  COMMAND ${WGET_EXECUTABLE} wget -P dl -N libstdc++.tag.tmp http://gcc.gnu.org/onlinedocs/libstdc++/latest-doxygen/libstdc++.tag
-  COMMAND ${CMAKE_COMMAND} -E rename dl/libstdc++.tag libstdc++.tag
-  COMMAND ${CMAKE_COMMAND} -E remove dl/libstdc++.tag
-  COMMAND ${CMAKE_COMMAND} -E remove_directory dl
-  WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
-  )
-ENDIF()
Index: doc/Doxyfile.in
===================================================================
--- doc/Doxyfile.in	(revision 908)
+++ doc/Doxyfile.in	(revision 756)
@@ -1,3 +1,3 @@
-# Doxyfile 1.7.3
+# Doxyfile 1.5.9
 
 #---------------------------------------------------------------------------
@@ -5,8 +5,6 @@
 #---------------------------------------------------------------------------
 DOXYFILE_ENCODING      = UTF-8
-PROJECT_NAME           = 
-PROJECT_NUMBER         = 
-PROJECT_BRIEF          =
-PROJECT_LOGO           =
+PROJECT_NAME           = @PACKAGE_NAME@
+PROJECT_NUMBER         = @PACKAGE_VERSION@
 OUTPUT_DIRECTORY       = 
 CREATE_SUBDIRS         = NO
@@ -32,5 +30,4 @@
 OPTIMIZE_FOR_FORTRAN   = NO
 OPTIMIZE_OUTPUT_VHDL   = NO
-EXTENSION_MAPPING      =
 BUILTIN_STL_SUPPORT    = YES
 CPP_CLI_SUPPORT        = NO
@@ -58,12 +55,9 @@
 HIDE_SCOPE_NAMES       = YES
 SHOW_INCLUDE_FILES     = YES
-FORCE_LOCAL_INCLUDES   = NO
 INLINE_INFO            = YES
 SORT_MEMBER_DOCS       = NO
 SORT_BRIEF_DOCS        = NO
-SORT_MEMBERS_CTORS_1ST = NO
 SORT_GROUP_NAMES       = NO
 SORT_BY_SCOPE_NAME     = NO
-STRICT_PROTO_MATCHING  = NO
 GENERATE_TODOLIST      = YES
 GENERATE_TESTLIST      = YES
@@ -77,5 +71,5 @@
 SHOW_NAMESPACES        = YES
 FILE_VERSION_FILTER    = 
-LAYOUT_FILE            = "@abs_top_srcdir@/doc/DoxygenLayout.xml"
+LAYOUT_FILE            = DoxygenLayout.xml
 #---------------------------------------------------------------------------
 # configuration options related to warning and progress messages
@@ -98,5 +92,4 @@
                          "@abs_top_srcdir@/tools" \
                          "@abs_top_srcdir@/test/test_tools.h" \
-                         "@abs_top_builddir@/doc/mainpage.dox" \
                          "@abs_top_builddir@/doc/references.dox"
 INPUT_ENCODING         = UTF-8
@@ -119,9 +112,8 @@
 FILTER_PATTERNS        = 
 FILTER_SOURCE_FILES    = NO
-FILTER_SOURCE_PATTERNS =
 #---------------------------------------------------------------------------
 # configuration options related to source browsing
 #---------------------------------------------------------------------------
-SOURCE_BROWSER         = @LEMON_DOC_SOURCE_BROWSER@
+SOURCE_BROWSER         = NO
 INLINE_SOURCES         = NO
 STRIP_CODE_COMMENTS    = YES
@@ -146,15 +138,9 @@
 HTML_FOOTER            = 
 HTML_STYLESHEET        = 
-HTML_COLORSTYLE_HUE    = 220
-HTML_COLORSTYLE_SAT    = 100
-HTML_COLORSTYLE_GAMMA  = 80
-HTML_TIMESTAMP         = YES
 HTML_ALIGN_MEMBERS     = YES
-HTML_DYNAMIC_SECTIONS  = YES
+HTML_DYNAMIC_SECTIONS  = NO
 GENERATE_DOCSET        = NO
 DOCSET_FEEDNAME        = "Doxygen generated docs"
 DOCSET_BUNDLE_ID       = org.doxygen.Project
-DOCSET_PUBLISHER_ID    = org.doxygen.Publisher
-DOCSET_PUBLISHER_NAME  = Publisher
 GENERATE_HTMLHELP      = NO
 CHM_FILE               = 
@@ -168,22 +154,10 @@
 QHP_NAMESPACE          = org.doxygen.Project
 QHP_VIRTUAL_FOLDER     = doc
-QHP_CUST_FILTER_NAME   =
-QHP_CUST_FILTER_ATTRS  =
-QHP_SECT_FILTER_ATTRS  =
 QHG_LOCATION           = 
-GENERATE_ECLIPSEHELP   = NO
-ECLIPSE_DOC_ID         = org.doxygen.Project
 DISABLE_INDEX          = NO
 ENUM_VALUES_PER_LINE   = 4
 GENERATE_TREEVIEW      = NO
-USE_INLINE_TREES       = NO
 TREEVIEW_WIDTH         = 250
-EXT_LINKS_IN_WINDOW    = NO
 FORMULA_FONTSIZE       = 10
-FORMULA_TRANSPARENT    = YES
-USE_MATHJAX            = NO
-MATHJAX_RELPATH        = http://www.mathjax.org/mathjax
-SEARCHENGINE           = YES
-SERVER_BASED_SEARCH    = NO
 #---------------------------------------------------------------------------
 # configuration options related to the LaTeX output
@@ -202,5 +176,4 @@
 LATEX_BATCHMODE        = NO
 LATEX_HIDE_INDICES     = NO
-LATEX_SOURCE_CODE      = NO
 #---------------------------------------------------------------------------
 # configuration options related to the RTF output
@@ -251,7 +224,7 @@
 SKIP_FUNCTION_MACROS   = YES
 #---------------------------------------------------------------------------
-# Configuration::additions related to external references
-#---------------------------------------------------------------------------
-TAGFILES               = "@abs_top_builddir@/doc/libstdc++.tag = http://gcc.gnu.org/onlinedocs/libstdc++/latest-doxygen/  "
+# Options related to the search engine   
+#---------------------------------------------------------------------------
+TAGFILES               = "@abs_top_srcdir@/doc/libstdc++.tag = http://gcc.gnu.org/onlinedocs/libstdc++/latest-doxygen/  "
 GENERATE_TAGFILE       = html/lemon.tag
 ALLEXTERNALS           = NO
@@ -265,5 +238,4 @@
 HIDE_UNDOC_RELATIONS   = YES
 HAVE_DOT               = YES
-DOT_NUM_THREADS        = 0
 DOT_FONTNAME           = FreeSans
 DOT_FONTSIZE           = 10
@@ -283,5 +255,4 @@
 DOT_PATH               = 
 DOTFILE_DIRS           = 
-MSCFILE_DIRS           =
 DOT_GRAPH_MAX_NODES    = 50
 MAX_DOT_GRAPH_DEPTH    = 0
@@ -290,2 +261,6 @@
 GENERATE_LEGEND        = YES
 DOT_CLEANUP            = YES
+#---------------------------------------------------------------------------
+# Configuration::additions related to the search engine   
+#---------------------------------------------------------------------------
+SEARCHENGINE           = NO
Index: doc/DoxygenLayout.xml
===================================================================
--- doc/DoxygenLayout.xml	(revision 906)
+++ doc/DoxygenLayout.xml	(revision 316)
@@ -3,22 +3,22 @@
   <navindex>
     <tab type="mainpage" visible="yes" title=""/>
-    <tab type="modules" visible="yes" title="" intro=""/>
+    <tab type="modules" visible="yes" title=""/>
     <tab type="classes" visible="yes" title="">
-      <tab type="classes" visible="yes" title="" intro=""/>
-      <tab type="classindex" visible="$ALPHABETICAL_INDEX" title=""/>
-      <tab type="hierarchy" visible="yes" title="" intro=""/>
-      <tab type="classmembers" visible="yes" title="" intro=""/>
+      <tab type="classes" visible="yes" title=""/>
+      <tab type="classindex" visible="$ALPHABETICAL_INDEX" title=""/> 
+      <tab type="hierarchy" visible="yes" title=""/>
+      <tab type="classmembers" visible="yes" title=""/>
     </tab>
     <tab type="namespaces" visible="yes" title="">
-      <tab type="namespaces" visible="yes" title="" intro=""/>
-      <tab type="namespacemembers" visible="yes" title="" intro=""/>
+      <tab type="namespaces" visible="yes" title=""/>
+      <tab type="namespacemembers" visible="yes" title=""/>
     </tab>
     <tab type="files" visible="yes" title="">
-      <tab type="files" visible="yes" title="" intro=""/>
-      <tab type="globals" visible="yes" title="" intro=""/>
+      <tab type="files" visible="yes" title=""/>
+      <tab type="globals" visible="yes" title=""/>
     </tab>
-    <tab type="dirs" visible="yes" title="" intro=""/>
-    <tab type="examples" visible="yes" title="" intro=""/>
-    <tab type="pages" visible="yes" title="" intro=""/>
+    <tab type="dirs" visible="yes" title=""/>
+    <tab type="examples" visible="yes" title=""/>  
+    <tab type="pages" visible="yes" title=""/>
   </navindex>
 
Index: doc/groups.dox
===================================================================
--- doc/groups.dox	(revision 884)
+++ doc/groups.dox	(revision 877)
@@ -264,4 +264,12 @@
 
 /**
+@defgroup matrices Matrices
+@ingroup datas
+\brief Two dimensional data storages implemented in LEMON.
+
+This group contains two dimensional data storages implemented in LEMON.
+*/
+
+/**
 @defgroup auxdat Auxiliary Data Structures
 @ingroup datas
@@ -284,4 +292,12 @@
    rectangular bounding box of a set of \ref lemon::dim2::Point
    "dim2::Point"'s.
+*/
+
+/**
+@defgroup matrices Matrices
+@ingroup auxdat
+\brief Two dimensional data storages implemented in LEMON.
+
+This group contains two dimensional data storages implemented in LEMON.
 */
 
@@ -319,4 +335,8 @@
    but the digraph should not contain directed cycles with negative total
    length.
+ - \ref FloydWarshall "Floyd-Warshall" and \ref Johnson "Johnson" algorithms
+   for solving the \e all-pairs \e shortest \e paths \e problem when arc
+   lenghts can be either positive or negative, but the digraph should
+   not contain directed cycles with negative total length.
  - \ref Suurballe A successive shortest path algorithm for finding
    arc-disjoint paths between two nodes having minimum total length.
@@ -352,8 +372,18 @@
 \f[ 0 \leq f(uv) \leq cap(uv) \quad \forall uv\in A \f]
 
-\ref Preflow is an efficient implementation of Goldberg-Tarjan's
-preflow push-relabel algorithm \ref goldberg88newapproach for finding
-maximum flows. It also provides functions to query the minimum cut,
-which is the dual problem of maximum flow.
+LEMON contains several algorithms for solving maximum flow problems:
+- \ref EdmondsKarp Edmonds-Karp algorithm
+  \ref edmondskarp72theoretical.
+- \ref Preflow Goldberg-Tarjan's preflow push-relabel algorithm
+  \ref goldberg88newapproach.
+- \ref DinitzSleatorTarjan Dinitz's blocking flow algorithm with dynamic trees
+  \ref dinic70algorithm, \ref sleator83dynamic.
+- \ref GoldbergTarjan !Preflow push-relabel algorithm with dynamic trees
+  \ref goldberg88newapproach, \ref sleator83dynamic.
+
+In most cases the \ref Preflow algorithm provides the
+fastest method for computing a maximum flow. All implementations
+also provide functions to query the minimum cut, which is the dual
+problem of maximum flow.
 
 \ref Circulation is a preflow push-relabel algorithm implemented directly
@@ -412,4 +442,6 @@
 - \ref HaoOrlin "Hao-Orlin algorithm" for calculating minimum cut
   in directed graphs.
+- \ref NagamochiIbaraki "Nagamochi-Ibaraki algorithm" for
+  calculating minimum cut in undirected graphs.
 - \ref GomoryHu "Gomory-Hu tree computation" for calculating
   all-pairs minimum cut in undirected graphs.
@@ -441,17 +473,17 @@
 
 LEMON contains three algorithms for solving the minimum mean cycle problem:
-- \ref KarpMmc Karp's original algorithm \ref amo93networkflows,
+- \ref Karp "Karp"'s original algorithm \ref amo93networkflows,
   \ref dasdan98minmeancycle.
-- \ref HartmannOrlinMmc Hartmann-Orlin's algorithm, which is an improved
+- \ref HartmannOrlin "Hartmann-Orlin"'s algorithm, which is an improved
   version of Karp's algorithm \ref dasdan98minmeancycle.
-- \ref HowardMmc Howard's policy iteration algorithm
+- \ref Howard "Howard"'s policy iteration algorithm
   \ref dasdan98minmeancycle.
 
-In practice, the \ref HowardMmc "Howard" algorithm proved to be by far the
-most efficient one, though the best known theoretical bound on its running
-time is exponential.
-Both \ref KarpMmc "Karp" and \ref HartmannOrlinMmc "Hartmann-Orlin" algorithms
-run in time O(ne) and use space O(n<sup>2</sup>+e), but the latter one is
-typically faster due to the applied early termination scheme.
+In practice, the Howard algorithm proved to be by far the most efficient
+one, though the best known theoretical bound on its running time is
+exponential.
+Both Karp and HartmannOrlin algorithms run in time O(ne) and use space
+O(n<sup>2</sup>+e), but the latter one is typically faster due to the
+applied early termination scheme.
 */
 
@@ -474,4 +506,14 @@
 
 The matching algorithms implemented in LEMON:
+- \ref MaxBipartiteMatching Hopcroft-Karp augmenting path algorithm
+  for calculating maximum cardinality matching in bipartite graphs.
+- \ref PrBipartiteMatching Push-relabel algorithm
+  for calculating maximum cardinality matching in bipartite graphs.
+- \ref MaxWeightedBipartiteMatching
+  Successive shortest path algorithm for calculating maximum weighted
+  matching and maximum weighted bipartite matching in bipartite graphs.
+- \ref MinCostMaxBipartiteMatching
+  Successive shortest path algorithm for calculating minimum cost maximum
+  matching in bipartite graphs.
 - \ref MaxMatching Edmond's blossom shrinking algorithm for calculating
   maximum cardinality matching in general graphs.
@@ -518,4 +560,13 @@
 
 /**
+@defgroup approx Approximation Algorithms
+@ingroup algs
+\brief Approximation algorithms.
+
+This group contains the approximation and heuristic algorithms
+implemented in LEMON.
+*/
+
+/**
 @defgroup auxalg Auxiliary Algorithms
 @ingroup algs
@@ -546,4 +597,21 @@
 The currently supported solvers are \ref glpk, \ref clp, \ref cbc,
 \ref cplex, \ref soplex.
+*/
+
+/**
+@defgroup lp_utils Tools for Lp and Mip Solvers
+@ingroup lp_group
+\brief Helper tools to the Lp and Mip solvers.
+
+This group adds some helper tools to general optimization framework
+implemented in LEMON.
+*/
+
+/**
+@defgroup metah Metaheuristics
+@ingroup gen_opt_group
+\brief Metaheuristics for LEMON library.
+
+This group contains some metaheuristic optimization tools.
 */
 
Index: doc/mainpage.dox
===================================================================
--- doc/mainpage.dox	(revision 877)
+++ doc/mainpage.dox	(revision 877)
@@ -0,0 +1,61 @@
+/* -*- mode: C++; indent-tabs-mode: nil; -*-
+ *
+ * This file is a part of LEMON, a generic C++ optimization library.
+ *
+ * Copyright (C) 2003-2010
+ * Egervary Jeno Kombinatorikus Optimalizalasi Kutatocsoport
+ * (Egervary Research Group on Combinatorial Optimization, EGRES).
+ *
+ * Permission to use, modify and distribute this software is granted
+ * provided that this copyright notice appears in all copies. For
+ * precise terms see the accompanying LICENSE file.
+ *
+ * This software is provided "AS IS" with no warranty of any kind,
+ * express or implied, and with no claim as to its suitability for any
+ * purpose.
+ *
+ */
+
+/**
+\mainpage LEMON Documentation
+
+\section intro Introduction
+
+<b>LEMON</b> stands for <i><b>L</b>ibrary for <b>E</b>fficient <b>M</b>odeling
+and <b>O</b>ptimization in <b>N</b>etworks</i>.
+It is a C++ template library providing efficient implementations of common
+data structures and algorithms with focus on combinatorial optimization
+tasks connected mainly with graphs and networks.
+
+<b>
+LEMON is an <a class="el" href="http://opensource.org/">open&nbsp;source</a>
+project.
+You are free to use it in your commercial or
+non-commercial applications under very permissive
+\ref license "license terms".
+</b>
+
+The project is maintained by the
+<a href="http://www.cs.elte.hu/egres/">Egerv&aacute;ry Research Group on
+Combinatorial Optimization</a> \ref egres
+at the Operations Research Department of the
+<a href="http://www.elte.hu/en/">E&ouml;tv&ouml;s Lor&aacute;nd University</a>,
+Budapest, Hungary.
+LEMON is also a member of the <a href="http://www.coin-or.org/">COIN-OR</a>
+initiative \ref coinor.
+
+\section howtoread How to Read the Documentation
+
+If you would like to get to know the library, see
+<a class="el" href="http://lemon.cs.elte.hu/pub/tutorial/">LEMON Tutorial</a>.
+
+If you are interested in starting to use the library, see the <a class="el"
+href="http://lemon.cs.elte.hu/trac/lemon/wiki/InstallGuide/">Installation
+Guide</a>.
+
+If you know what you are looking for, then try to find it under the
+<a class="el" href="modules.html">Modules</a> section.
+
+If you are a user of the old (0.x) series of LEMON, please check out the
+\ref migration "Migration Guide" for the backward incompatibilities.
+*/
Index: c/mainpage.dox.in
===================================================================
--- doc/mainpage.dox.in	(revision 908)
+++ 	(revision )
@@ -1,61 +1,0 @@
-/* -*- mode: C++; indent-tabs-mode: nil; -*-
- *
- * This file is a part of LEMON, a generic C++ optimization library.
- *
- * Copyright (C) 2003-2010
- * Egervary Jeno Kombinatorikus Optimalizalasi Kutatocsoport
- * (Egervary Research Group on Combinatorial Optimization, EGRES).
- *
- * Permission to use, modify and distribute this software is granted
- * provided that this copyright notice appears in all copies. For
- * precise terms see the accompanying LICENSE file.
- *
- * This software is provided "AS IS" with no warranty of any kind,
- * express or implied, and with no claim as to its suitability for any
- * purpose.
- *
- */
-
-/**
-\mainpage @PACKAGE_NAME@ @PACKAGE_VERSION@ Documentation
-
-\section intro Introduction
-
-<b>LEMON</b> stands for <i><b>L</b>ibrary for <b>E</b>fficient <b>M</b>odeling
-and <b>O</b>ptimization in <b>N</b>etworks</i>.
-It is a C++ template library providing efficient implementations of common
-data structures and algorithms with focus on combinatorial optimization
-tasks connected mainly with graphs and networks.
-
-<b>
-LEMON is an <a class="el" href="http://opensource.org/">open&nbsp;source</a>
-project.
-You are free to use it in your commercial or
-non-commercial applications under very permissive
-\ref license "license terms".
-</b>
-
-The project is maintained by the
-<a href="http://www.cs.elte.hu/egres/">Egerv&aacute;ry Research Group on
-Combinatorial Optimization</a> \ref egres
-at the Operations Research Department of the
-<a href="http://www.elte.hu/en/">E&ouml;tv&ouml;s Lor&aacute;nd University</a>,
-Budapest, Hungary.
-LEMON is also a member of the <a href="http://www.coin-or.org/">COIN-OR</a>
-initiative \ref coinor.
-
-\section howtoread How to Read the Documentation
-
-If you would like to get to know the library, see
-<a class="el" href="http://lemon.cs.elte.hu/pub/tutorial/">LEMON Tutorial</a>.
-
-If you are interested in starting to use the library, see the <a class="el"
-href="http://lemon.cs.elte.hu/trac/lemon/wiki/InstallGuide/">Installation
-Guide</a>.
-
-If you know what you are looking for, then try to find it under the
-<a class="el" href="modules.html">Modules</a> section.
-
-If you are a user of the old (0.x) series of LEMON, please check out the
-\ref migration "Migration Guide" for the backward incompatibilities.
-*/
Index: lemon/CMakeLists.txt
===================================================================
--- lemon/CMakeLists.txt	(revision 904)
+++ lemon/CMakeLists.txt	(revision 679)
@@ -7,10 +7,4 @@
   ${CMAKE_CURRENT_SOURCE_DIR}/config.h.cmake
   ${CMAKE_CURRENT_BINARY_DIR}/config.h
-)
-
-CONFIGURE_FILE(
-  ${CMAKE_CURRENT_SOURCE_DIR}/lemon.pc.cmake
-  ${CMAKE_CURRENT_BINARY_DIR}/lemon.pc
-  @ONLY
 )
 
@@ -73,8 +67,2 @@
   COMPONENT headers
 )
-
-INSTALL(
-  FILES ${CMAKE_CURRENT_BINARY_DIR}/lemon.pc
-  DESTINATION lib/pkgconfig
-)
-
Index: lemon/arg_parser.h
===================================================================
--- lemon/arg_parser.h	(revision 880)
+++ lemon/arg_parser.h	(revision 877)
@@ -36,17 +36,10 @@
 
   ///Exception used by ArgParser
-
-  ///Exception used by ArgParser.
-  ///
   class ArgParserException : public Exception {
   public:
-    /// Reasons for failure
-
-    /// Reasons for failure.
-    ///
     enum Reason {
-      HELP,         ///< <tt>--help</tt> option was given.
-      UNKNOWN_OPT,  ///< Unknown option was given.
-      INVALID_OPT   ///< Invalid combination of options.
+      HELP,         /// <tt>--help</tt> option was given
+      UNKNOWN_OPT,  /// Unknown option was given
+      INVALID_OPT   /// Invalid combination of options
     };
 
Index: lemon/bellman_ford.h
===================================================================
--- lemon/bellman_ford.h	(revision 881)
+++ lemon/bellman_ford.h	(revision 877)
@@ -29,4 +29,5 @@
 #include <lemon/error.h>
 #include <lemon/maps.h>
+#include <lemon/tolerance.h>
 #include <lemon/path.h>
 
@@ -35,5 +36,5 @@
 namespace lemon {
 
-  /// \brief Default OperationTraits for the BellmanFord algorithm class.
+  /// \brief Default operation traits for the BellmanFord algorithm class.
   ///
   /// This operation traits class defines all computational operations
@@ -42,9 +43,11 @@
   /// If the numeric type does not have infinity value, then the maximum
   /// value is used as extremal infinity value.
+  ///
+  /// \see BellmanFordToleranceOperationTraits
   template <
     typename V,
     bool has_inf = std::numeric_limits<V>::has_infinity>
   struct BellmanFordDefaultOperationTraits {
-    /// \e
+    /// \brief Value type for the algorithm.
     typedef V Value;
     /// \brief Gives back the zero value of the type.
@@ -82,4 +85,49 @@
     static bool less(const Value& left, const Value& right) {
       return left < right;
+    }
+  };
+
+  /// \brief Operation traits for the BellmanFord algorithm class
+  /// using tolerance.
+  ///
+  /// This operation traits class defines all computational operations
+  /// and constants that are used in the Bellman-Ford algorithm.
+  /// The only difference between this implementation and
+  /// \ref BellmanFordDefaultOperationTraits is that this class uses
+  /// the \ref Tolerance "tolerance technique" in its \ref less()
+  /// function.
+  ///
+  /// \tparam V The value type.
+  /// \tparam eps The epsilon value for the \ref less() function.
+  /// By default, it is the epsilon value used by \ref Tolerance
+  /// "Tolerance<V>".
+  ///
+  /// \see BellmanFordDefaultOperationTraits
+#ifdef DOXYGEN
+  template <typename V, V eps>
+#else
+  template <
+    typename V,
+    V eps = Tolerance<V>::def_epsilon>
+#endif
+  struct BellmanFordToleranceOperationTraits {
+    /// \brief Value type for the algorithm.
+    typedef V Value;
+    /// \brief Gives back the zero value of the type.
+    static Value zero() {
+      return static_cast<Value>(0);
+    }
+    /// \brief Gives back the positive infinity value of the type.
+    static Value infinity() {
+      return std::numeric_limits<Value>::infinity();
+    }
+    /// \brief Gives back the sum of the given two elements.
+    static Value plus(const Value& left, const Value& right) {
+      return left + right;
+    }
+    /// \brief Gives back \c true only if the first value is less than
+    /// the second.
+    static bool less(const Value& left, const Value& right) {
+      return left + eps < right;
     }
   };
@@ -108,5 +156,6 @@
     /// It defines the used operations and the infinity value for the
     /// given \c Value type.
-    /// \see BellmanFordDefaultOperationTraits
+    /// \see BellmanFordDefaultOperationTraits,
+    /// BellmanFordToleranceOperationTraits
     typedef BellmanFordDefaultOperationTraits<Value> OperationTraits;
 
@@ -838,5 +887,6 @@
     /// It defines the used operations and the infinity value for the
     /// given \c Value type.
-    /// \see BellmanFordDefaultOperationTraits
+    /// \see BellmanFordDefaultOperationTraits,
+    /// BellmanFordToleranceOperationTraits
     typedef BellmanFordDefaultOperationTraits<Value> OperationTraits;
 
Index: lemon/bits/edge_set_extender.h
===================================================================
--- lemon/bits/edge_set_extender.h	(revision 887)
+++ lemon/bits/edge_set_extender.h	(revision 877)
@@ -281,6 +281,4 @@
     typedef EdgeSetExtender Graph;
 
-    typedef True UndirectedTag;
-
     typedef typename Parent::Node Node;
     typedef typename Parent::Arc Arc;
Index: lemon/bits/graph_adaptor_extender.h
===================================================================
--- lemon/bits/graph_adaptor_extender.h	(revision 886)
+++ lemon/bits/graph_adaptor_extender.h	(revision 617)
@@ -182,6 +182,4 @@
     typedef GraphAdaptorExtender Adaptor;
 
-    typedef True UndirectedTag;
-
     typedef typename Parent::Node Node;
     typedef typename Parent::Arc Arc;
Index: lemon/bits/path_dump.h
===================================================================
--- lemon/bits/path_dump.h	(revision 890)
+++ lemon/bits/path_dump.h	(revision 529)
@@ -50,5 +50,5 @@
 
     bool empty() const {
-      return predMap[target] == INVALID;
+      return predMap[target] != INVALID;
     }
 
@@ -124,5 +124,5 @@
 
     bool empty() const {
-      return predMatrixMap(source, target) == INVALID;
+      return source != target;
     }
 
Index: lemon/core.h
===================================================================
--- lemon/core.h	(revision 896)
+++ lemon/core.h	(revision 877)
@@ -395,5 +395,4 @@
       static void copy(const From& from, Digraph &to,
                        NodeRefMap& nodeRefMap, ArcRefMap& arcRefMap) {
-        to.clear();
         for (typename From::NodeIt it(from); it != INVALID; ++it) {
           nodeRefMap[it] = to.addNode();
@@ -423,5 +422,4 @@
       static void copy(const From& from, Graph &to,
                        NodeRefMap& nodeRefMap, EdgeRefMap& edgeRefMap) {
-        to.clear();
         for (typename From::NodeIt it(from); it != INVALID; ++it) {
           nodeRefMap[it] = to.addNode();
Index: lemon/cost_scaling.h
===================================================================
--- lemon/cost_scaling.h	(revision 877)
+++ lemon/cost_scaling.h	(revision 909)
@@ -908,5 +908,5 @@
           break;
         case AUGMENT:
-          startAugment();
+          startAugment(_res_node_num - 1);
           break;
         case PARTIAL_AUGMENT:
@@ -1085,5 +1085,5 @@
 
     /// Execute the algorithm performing augment and relabel operations
-    void startAugment(int max_length = std::numeric_limits<int>::max()) {
+    void startAugment(int max_length) {
       // Paramters for heuristics
       const int EARLY_TERM_EPSILON_LIMIT = 1000;
Index: lemon/dfs.h
===================================================================
--- lemon/dfs.h	(revision 900)
+++ lemon/dfs.h	(revision 877)
@@ -566,5 +566,5 @@
     void start(Node t)
     {
-      while ( !emptyQueue() && !(*_reached)[t] )
+      while ( !emptyQueue() && G->target(_stack[_stack_head])!=t )
         processNextArc();
     }
@@ -1513,5 +1513,5 @@
     /// with addSource() before using this function.
     void start(Node t) {
-      while ( !emptyQueue() && !(*_reached)[t] )
+      while ( !emptyQueue() && _digraph->target(_stack[_stack_head]) != t )
         processNextArc();
     }
Index: lemon/hartmann_orlin_mmc.h
===================================================================
--- lemon/hartmann_orlin_mmc.h	(revision 880)
+++ lemon/hartmann_orlin_mmc.h	(revision 877)
@@ -39,5 +39,5 @@
   /// \tparam GR The type of the digraph.
   /// \tparam CM The type of the cost map.
-  /// It must conform to the \ref concepts::ReadMap "ReadMap" concept.
+  /// It must conform to the \ref concepts::Rea_data "Rea_data" concept.
 #ifdef DOXYGEN
   template <typename GR, typename CM>
@@ -100,5 +100,5 @@
   /// a directed cycle of minimum mean cost in a digraph
   /// \ref amo93networkflows, \ref dasdan98minmeancycle.
-  /// It is an improved version of \ref KarpMmc "Karp"'s original algorithm,
+  /// It is an improved version of \ref Karp "Karp"'s original algorithm,
   /// it applies an efficient early termination scheme.
   /// It runs in time O(ne) and uses space O(n<sup>2</sup>+e).
Index: mon/lemon.pc.cmake
===================================================================
--- lemon/lemon.pc.cmake	(revision 904)
+++ 	(revision )
@@ -1,10 +1,0 @@
-prefix=@CMAKE_INSTALL_PREFIX@
-exec_prefix=@CMAKE_INSTALL_PREFIX@/bin
-libdir=@CMAKE_INSTALL_PREFIX@/lib
-includedir=@CMAKE_INSTALL_PREFIX@/include
-
-Name: @PROJECT_NAME@
-Description: Library for Efficient Modeling and Optimization in Networks
-Version: @PROJECT_VERSION@
-Libs: -L${libdir} -lemon @GLPK_LIBS@ @CPLEX_LIBS@ @SOPLEX_LIBS@ @CLP_LIBS@ @CBC_LIBS@
-Cflags: -I${includedir}
Index: lemon/network_simplex.h
===================================================================
--- lemon/network_simplex.h	(revision 892)
+++ lemon/network_simplex.h	(revision 877)
@@ -1078,5 +1078,5 @@
         ART_COST = std::numeric_limits<Cost>::max() / 2 + 1;
       } else {
-        ART_COST = 0;
+        ART_COST = std::numeric_limits<Cost>::min();
         for (int i = 0; i != _arc_num; ++i) {
           if (_cost[i] > ART_COST) ART_COST = _cost[i];
@@ -1590,5 +1590,5 @@
       if (_sum_supply == 0) {
         if (_stype == GEQ) {
-          Cost max_pot = -std::numeric_limits<Cost>::max();
+          Cost max_pot = std::numeric_limits<Cost>::min();
           for (int i = 0; i != _node_num; ++i) {
             if (_pi[i] > max_pot) max_pot = _pi[i];
Index: lemon/preflow.h
===================================================================
--- lemon/preflow.h	(revision 902)
+++ lemon/preflow.h	(revision 877)
@@ -544,4 +544,7 @@
           _flow->set(e, (*_capacity)[e]);
           (*_excess)[u] += rem;
+          if (u != _target && !_level->active(u)) {
+            _level->activate(u);
+          }
         }
       }
@@ -553,10 +556,9 @@
           _flow->set(e, 0);
           (*_excess)[v] += rem;
-        }
-      }
-      for (NodeIt n(_graph); n != INVALID; ++n) 
-        if(n!=_source && n!=_target && _tolerance.positive((*_excess)[n]))
-          _level->activate(n);
-          
+          if (v != _target && !_level->active(v)) {
+            _level->activate(v);
+          }
+        }
+      }
       return true;
     }
@@ -575,16 +577,10 @@
       _phase = true;
 
-      while (true) {
+      Node n = _level->highestActive();
+      int level = _level->highestActiveLevel();
+      while (n != INVALID) {
         int num = _node_num;
 
-        Node n = INVALID;
-        int level = -1;
-
-        while (num > 0) {
-          n = _level->highestActive();
-          if (n == INVALID) goto first_phase_done;
-          level = _level->highestActiveLevel();
-          --num;
-          
+        while (num > 0 && n != INVALID) {
           Value excess = (*_excess)[n];
           int new_level = _level->maxLevel();
@@ -652,20 +648,12 @@
             _level->deactivate(n);
           }
+
+          n = _level->highestActive();
+          level = _level->highestActiveLevel();
+          --num;
         }
 
         num = _node_num * 20;
-        while (num > 0) {
-          while (level >= 0 && _level->activeFree(level)) {
-            --level;
-          }
-          if (level == -1) {
-            n = _level->highestActive();
-            level = _level->highestActiveLevel();
-            if (n == INVALID) goto first_phase_done;
-          } else {
-            n = _level->activeOn(level);
-          }
-          --num;
-
+        while (num > 0 && n != INVALID) {
           Value excess = (*_excess)[n];
           int new_level = _level->maxLevel();
@@ -733,7 +721,17 @@
             _level->deactivate(n);
           }
-        }
-      }
-    first_phase_done:;
+
+          while (level >= 0 && _level->activeFree(level)) {
+            --level;
+          }
+          if (level == -1) {
+            n = _level->highestActive();
+            level = _level->highestActiveLevel();
+          } else {
+            n = _level->activeOn(level);
+          }
+          --num;
+        }
+      }
     }
 
Index: test/CMakeLists.txt
===================================================================
--- test/CMakeLists.txt	(revision 905)
+++ test/CMakeLists.txt	(revision 874)
@@ -46,10 +46,5 @@
 
 IF(LEMON_HAVE_LP)
-  IF(${CMAKE_BUILD_TYPE} STREQUAL "Maintainer")
-    ADD_EXECUTABLE(lp_test lp_test.cc)
-  ELSE()
-    ADD_EXECUTABLE(lp_test EXCLUDE_FROM_ALL lp_test.cc)
-  ENDIF()
-
+  ADD_EXECUTABLE(lp_test lp_test.cc)
   SET(LP_TEST_LIBS lemon)
 
@@ -87,10 +82,5 @@
 
 IF(LEMON_HAVE_MIP)
-  IF(${CMAKE_BUILD_TYPE} STREQUAL "Maintainer")
-    ADD_EXECUTABLE(mip_test mip_test.cc)
-  ELSE()
-    ADD_EXECUTABLE(mip_test EXCLUDE_FROM_ALL mip_test.cc)
-  ENDIF()
-
+  ADD_EXECUTABLE(mip_test mip_test.cc)
   SET(MIP_TEST_LIBS lemon)
 
@@ -128,11 +118,6 @@
 
 FOREACH(TEST_NAME ${TESTS})
-  IF(${CMAKE_BUILD_TYPE} STREQUAL "Maintainer")
-    ADD_EXECUTABLE(${TEST_NAME} ${TEST_NAME}.cc)
-  ELSE()
-    ADD_EXECUTABLE(${TEST_NAME} EXCLUDE_FROM_ALL ${TEST_NAME}.cc)
-  ENDIF()
+  ADD_EXECUTABLE(${TEST_NAME} ${TEST_NAME}.cc)
   TARGET_LINK_LIBRARIES(${TEST_NAME} lemon)
   ADD_TEST(${TEST_NAME} ${TEST_NAME})
-  ADD_DEPENDENCIES(check ${TEST_NAME})
 ENDFOREACH()
Index: test/bellman_ford_test.cc
===================================================================
--- test/bellman_ford_test.cc	(revision 881)
+++ test/bellman_ford_test.cc	(revision 877)
@@ -105,4 +105,5 @@
       ::SetDistMap<concepts::ReadWriteMap<Node,Value> >
       ::SetOperationTraits<BellmanFordDefaultOperationTraits<Value> >
+      ::SetOperationTraits<BellmanFordToleranceOperationTraits<Value, 0> >
       ::Create bf_test(gr,length);
 
Index: test/dfs_test.cc
===================================================================
--- test/dfs_test.cc	(revision 900)
+++ test/dfs_test.cc	(revision 877)
@@ -51,8 +51,5 @@
   "@attributes\n"
   "source 0\n"
-  "target 5\n"
-  "source1 6\n"
-  "target1 3\n";
-
+  "target 5\n";
 
 void checkDfsCompile()
@@ -183,5 +180,4 @@
   Digraph G;
   Node s, t;
-  Node s1, t1;
 
   std::istringstream input(test_lgf);
@@ -189,6 +185,4 @@
     node("source", s).
     node("target", t).
-    node("source1", s1).
-    node("target1", t1).
     run();
 
@@ -217,9 +211,4 @@
 
   {
-  Dfs<Digraph> dfs(G);
-  check(dfs.run(s1,t1) && dfs.reached(t1),"Node 3 is reachable from Node 6.");
-  }
-  
-  {
     NullMap<Node,Arc> myPredMap;
     dfs(G).predMap(myPredMap).run(s);
Index: test/graph_copy_test.cc
===================================================================
--- test/graph_copy_test.cc	(revision 896)
+++ test/graph_copy_test.cc	(revision 440)
@@ -30,5 +30,4 @@
   const int nn = 10;
 
-  // Build a digraph
   SmartDigraph from;
   SmartDigraph::NodeMap<int> fnm(from);
@@ -53,5 +52,4 @@
   }
 
-  // Test digraph copy
   ListDigraph to;
   ListDigraph::NodeMap<int> tnm(to);
@@ -71,7 +69,4 @@
     nodeCrossRef(ncr).arcCrossRef(ecr).
     node(fn, tn).arc(fa, ta).run();
-  
-  check(countNodes(from) == countNodes(to), "Wrong copy.");
-  check(countArcs(from) == countArcs(to), "Wrong copy.");
 
   for (SmartDigraph::NodeIt it(from); it != INVALID; ++it) {
@@ -96,10 +91,4 @@
   check(tn == nr[fn], "Wrong copy.");
   check(ta == er[fa], "Wrong copy.");
-
-  // Test repeated copy
-  digraphCopy(from, to).run();
-  
-  check(countNodes(from) == countNodes(to), "Wrong copy.");
-  check(countArcs(from) == countArcs(to), "Wrong copy.");
 }
 
@@ -107,5 +96,4 @@
   const int nn = 10;
 
-  // Build a graph
   SmartGraph from;
   SmartGraph::NodeMap<int> fnm(from);
@@ -135,5 +123,4 @@
   }
 
-  // Test graph copy
   ListGraph to;
   ListGraph::NodeMap<int> tnm(to);
@@ -157,8 +144,4 @@
     nodeCrossRef(ncr).arcCrossRef(acr).edgeCrossRef(ecr).
     node(fn, tn).arc(fa, ta).edge(fe, te).run();
-
-  check(countNodes(from) == countNodes(to), "Wrong copy.");
-  check(countEdges(from) == countEdges(to), "Wrong copy.");
-  check(countArcs(from) == countArcs(to), "Wrong copy.");
 
   for (SmartGraph::NodeIt it(from); it != INVALID; ++it) {
@@ -198,11 +181,4 @@
   check(ta == ar[fa], "Wrong copy.");
   check(te == er[fe], "Wrong copy.");
-
-  // Test repeated copy
-  graphCopy(from, to).run();
-  
-  check(countNodes(from) == countNodes(to), "Wrong copy.");
-  check(countEdges(from) == countEdges(to), "Wrong copy.");
-  check(countArcs(from) == countArcs(to), "Wrong copy.");
 }
 
Index: test/preflow_test.cc
===================================================================
--- test/preflow_test.cc	(revision 902)
+++ test/preflow_test.cc	(revision 877)
@@ -157,28 +157,4 @@
 }
 
-void initFlowTest()
-{
-  DIGRAPH_TYPEDEFS(SmartDigraph);
-  
-  SmartDigraph g;
-  SmartDigraph::ArcMap<int> cap(g),iflow(g);
-  Node s=g.addNode(); Node t=g.addNode();
-  Node n1=g.addNode(); Node n2=g.addNode();
-  Arc a;
-  a=g.addArc(s,n1); cap[a]=20; iflow[a]=20;
-  a=g.addArc(n1,n2); cap[a]=10; iflow[a]=0;
-  a=g.addArc(n2,t); cap[a]=20; iflow[a]=0;
-
-  Preflow<SmartDigraph> pre(g,cap,s,t);
-  pre.init(iflow);
-  pre.startFirstPhase();
-  check(pre.flowValue() == 10, "The incorrect max flow value.");
-  check(pre.minCut(s), "Wrong min cut (Node s).");
-  check(pre.minCut(n1), "Wrong min cut (Node n1).");
-  check(!pre.minCut(n2), "Wrong min cut (Node n2).");
-  check(!pre.minCut(t), "Wrong min cut (Node t).");
-}
-
-
 int main() {
 
@@ -271,6 +247,4 @@
         "The max flow value or the three min cut values are incorrect.");
 
-  initFlowTest();
-  
   return 0;
 }
